[Gambas-user] HTML Tags in TextEditor is always foreground black

Martin Belmonte mbelmonte at belmotek.net
Thu Feb 10 09:19:53 CET 2022


El 10/2/22 a las 1:34, Benoît Minisini escribió:
> MyTheme = ThemeHighlighterTheme.Load(<path to theme file>)
> You get a ThemeHighlighterTheme object that you assign to your editor:
> MyEditor.Theme = MyTheme
> The 'ThemeHighlighterTheme.Load()' method takes care of not completely 
> defined theme file like 'zen.theme', and try to assign to non-defined 
> colors the other colors of the theme.

ok, perfect, solved. But for TextEditor... The method is 
TextHighlighterTheme.Load() and not ThemeHighlighterTheme.Load() right?

Public Sub AplyTheme(Optional strPath As String)
   Dim hTheme As TextHighlighterTheme
   If Application.DarkTheme Then
     hTheme = TextHighlighterTheme.Load("./editor-themes/dark.theme")
   Else
     hTheme = TextHighlighterTheme.Load("./editor-themes/zen.theme")
   Endif
   TextEditor1.Theme = hTheme
End

Thanks.


More information about the User mailing list