TextEditor foreground

Post

Posted
Rating:
#1 (In Topic #2081)
Avatar
Trainee
Berkut is in the usergroup ‘unknown’

Not working in Mint 22.3

Hello!

Small problem! I can't change the Foreground property of the TextEditor. Background works fine, but not Foreground.
Using Mint 22.3 and Gambas 3.21.4. qt4.
Anyone has the same problem or did I mess up something in my comp?

Thank you.
Online now: No Back to the top

Post

Posted
Rating:
#2
Avatar
Administrator
gbWilly is in the usergroup ‘unknown’
gbWilly is in the usergroup ‘Blogger’
gbWilly is in the usergroup ‘GambOS Developer’

Berkut said

Anyone has the same problem or did I mess up something in my comp?
You might have sabotaged your computer. Either that or…

TextEditor is a special control. The code editor in the IDE is a TextEditor.
You can set its Background, but the Text (Foreground) supports Syntax Highlighting, so forget about foreground.

TextEditor has a Highlight property to set the kind of highlight you want (like Gambas or sh etc)
TextEditor has a Theme property where you can set the highlight theme (just like in the IDE, theme is color combinations used to highlight the specific highlight chosen)

In illustration below my IDE code editor had Gambas Highlight, as it is Gambas code, but you can set the Theme, mine is Obsidian. This determines both the background (black) and colors used for foreground (highlighted text in multiple colors).

post.png

Highlight theme in Preferences set to Obsidian gives code highlighting as shown on the left

Read the wiki on TextEditor for details.

Enjoy.. :thumbs:

 

gbWilly
- Gambas Dutch translator
- Gambas wiki content contributor
- Gambas debian/ubuntu package recipe contributor
- GambOS, a distro for learning Gambas and more…
- Gambas3 Debian/Ubuntu repositories


… there is always a Catch if things go wrong!
Online now: No Back to the top
1 guest and 0 members have just viewed this.