We are using TMS FNC WX Pack 1.7.2.0. We found and got this confirmed in the summernote GitHub repository that dropdown menus (e.g. for font name and font size) are not dropping down in a modal window.
We fixed that in the TTMSFNCWXHTMLMemo component in the following way:
function TTMSFNCWXCustomHTMLMemo.GetCustomFunctions: string;
var
JSText: string;
begin
JSText := 'function ' + GetControlID + 'initializeEditor(){' + LB +
{$IFDEF WEBLIB}
'if (window.$(''#' + GetControlID + ''').siblings().length > 0) return;' + LB +
{$ENDIF}
'window.$(''#' + GetControlID + ''').summernote({' + LB +
ReplaceStr(CALLBACKSEVENTS, DATA_OBJECT, GetDefaultEventDataObject) + LB +
DISABLERESIZEEDITOR + LB + GetFontSizesList + LB + GetToolBarVisibleTag +
LB + GetCustomFontNames + LB + GetSpellCheck + LB
//*** FIX begin
{$IFNDEF WEBLIB}+ FOCUSTRUE + LB{$ENDIF} + '});' + LB +
'window.$(''#' + GetControlID + ''').next().find(''.dropdown-toggle'').dropdown();' + LB +
'}' + LB +
// FIX end
SUMNTJSSELECTEDTEXT + LB + SUMNTJSDEFAULTFONT + LB +
SUMNTJSFIRSTFONT + LB + SUMNTOGGLETOOLBAR + LB + SUMNTTOGGLESPELLCHECK;
JSText := ReplaceStr(JSText, JSHASHTAGSUMMERNOTEID, GetControlID);
Result := JSText;
end;
and
2.
procedure TTMSFNCWXCustomHTMLMemo.DoHandleFocusEvent;
//*** FIX begin
var
ltId : string;
//FIX end
begin
if Assigned(FOnFocus) then
FOnFocus(Self);
//*** FIX start
ltId := GetControlID;
asm
window.$('#' + ltId).next().find('.note-dropdown-menu').removeClass('show');
end;
//FIX end
end;