Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2010-01

lazarus editor coloring

4 messages · 3 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

ik

Hello list,

I've noticed two things that are missing at Lazarus:

1. The ability to add/save new color style I'm making
2. Loading custom made coloring

I always change the default coloring of Lazarus to extended the coloring, however I can't save it as a new coloring style.
Moreover I've noticed that on a darker places, a light editor is harder to work, and on a light place, a darker editor is harder to work with, so if I could replace such colors depending of my needs (that's where the saving come handy) it will be much easier to work with the editor imho.

Now the big question is, how do I add such feature to Lazarus ? What exactly does it require and what points do I need to know before doing such thing ?

Thanks,
Ido
http://ik.homelinux.org/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus.freepascal.org/pipermail/lazarus/attachments/20100121/4acab5f4/attachment.html>

Reply by email

Graeme Geldenhuys
to ik
ik wrote
1. The ability to add/save new color style I'm making 2. Loading custom made coloring

I've had the same issue, and have about 15 different color scheme files available. By files I mean a copies of the .xml file Lazarus generates.

Now the big question is, how do I add such feature to Lazarus ? What exactly does it require and what points do I need to know before doing

A few months back I created a patch which removes the "hard coded" color scheme idea, and instead existing color schemes register themselves with a singleton class. The patch was applied, but I haven't had the time to continue the work on importing and exporting new color schemes.

Things that need to be addressed:

* For one, I think the color scheme information should go into a separate .xml file and not be part of the editoroptions.xml file.

* I also think a "runtime" loading of color schemes is required. Lazarus comes standard with 5 or so, but when Lazarus starts up, it should also check a directory (eg: ~/.lazarus/colorschemes/) for any custom schemes and populate the scheme combobox with those too.

* If previously you used a custom color scheme and one restarting that scheme is not available, it should fall back to one of the default color schemes include with lazarus (always available).

Regards,
- Graeme -

fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal http://opensoft.homeip.net/fpgui/

Reply by email

Paul Ishenin
to ik: I've noticed two things that are missing at Lazarus: 1. The ability to add/save new color…
ik wrote 8 lines
I've noticed two things that are missing at Lazarus: 1. The ability to add/save new color style I'm making 2. Loading custom made coloring Now the big question is, how do I add such feature to Lazarus ? What exactly does it require and what points do I need to know before doing such thing ?

Look at ide\editoroptions.pp DEFAULT_COLOR_SCHEME, TWILIGHT_COLOR_SCHEME, ... I suppose you need to implement load and save of default color schemes from some scheme configuration file.

Best regards,
Paul Ishenin.

Reply by email

Graeme Geldenhuys
to ik: I've noticed two things that are missing at Lazarus: 1. The ability to add/save new color…
ik wrote
1. The ability to add/save new color style I'm making 2. Loading custom made coloring

The patch I was talking about is in r20123, and the global color scheme factor is accessed as:

  function ColorSchemeFactory: TColorSchemeFactory;

Regards,
- Graeme -

fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal http://opensoft.homeip.net/fpgui/

Reply by email