#622 Colour of current_line

open
nobody
5
2012-10-02
2012-10-02
Dimwick
No

Re: Geany 0.21, running in Xubuntu 12.04.
I have been trying, in vain, to set different colours for the "current_line", depending upon file type. It appears that the *only* option is the one set in "filetypes.common". Is this conclusion correct? If so, please may I add this to your feature wish list?

With thanks, Dimwick

Discussion

  • Lex Trotman
    Lex Trotman
    2012-10-02

    The filetype files can only set styles, not settings so it is a feature request.

    It would be more likely that someone would be interested in implementing it if you provided more information on what advantage this will provide?

     
  • Dimwick
    Dimwick
    2012-10-02

    The advantage of this feature? There are a number of different "colour themes" available, to suit a user's preferences. Some, as with myself, find a white screen to be just too bright. If we are to use a colour theme, then the current_line must be set to something more appropriate for that colour set. I use a light blue current_line colour, OK for a white background, but when this is combined with a dark background, it proves to be too bright.

    So if this setting for current_line could be moved to filetype.*, it could be set for each user's needs/preferences, to work in harmony with the colour theme, thus enhancing the user experience. In my opinion, this would be an advantage.

     
  • Lex Trotman
    Lex Trotman
    2012-10-02

    You are talking about colour schemes, not filetypes.

    The setting *is* part of the colour scheme file, so it can be set per colour scheme.

    The way colour schemes work changed in 1.22.

     
  • Dimwick
    Dimwick
    2012-10-02

    I am not talking about file types, but I am wanting to put current_line colour information (part of the colour scheme, if you wish) into a filetypes.* file. This would enable different colour current_lines for different filetypes. Presently I can make only one single setting, in filetypes.common.

    I think in terms of everything on the "paper" (old fashioned terminology) as being part of the "style". And just to clarify my concept, the borders, scroll bars, menus, etc, I would class as a theme. So I see current_line colour as a part of the style, and hence consider that it would not be out of place in a filetypes.* file.

    When you say "The setting *is* part of the colour scheme file, so it can be set per
    colour scheme.", that sounds hopeful. But how is this put into effect, ie by what command where? I ask this because using a current_line colour in a filetypes.* file will not work for me, so evidently I am doing something wrong!
    It is therefore possible to put the information for the current_line colour

     
  • Lex Trotman
    Lex Trotman
    2012-10-02

    As I said colour schemes changed in 1.22, you are using 0.21. The colour scheme file defines a "theme" for the editor and it includes current_line settings so you can set them to match the scheme.

    The filetypes files have never been able to set any settings beyond style foreground, background colours and bold and italic, and in 1.22 they are not supposed to set even those, instead inheriting them from the colour scheme. Filetype files have never been able to set any other settings like current_line.

    Alternate colour schemes are selected by menu->view->editor->colour schemes.

    The use of current_line in the colour schemes seems to match what you described in terms of wanting it to change when the colour scheme changes to say a dark scheme.

    If you really do want a different current_line for *each* filetype then you havn't explained why? For example why do you want the colour of the current_line different for C files from Python files?

     
  • Dimwick
    Dimwick
    2012-10-02

    So, it seems that the xubuntu repository is a bit behind the times! Obviously that will be part of the problem.

    You ask " For example why do you want the colour of the current_line different for C files from Python files?". Well probaly not, if the colours were already comfortable on the eye. But one colour scheme that I looked at had some characters that were all but invisible. To put it simply, my problem was, or rather is, that whichever colour scheme I choose, I am still stuck with the same current_line colour as set in filetypes.common.

    Thanking you for your comments,
    Dimwick
    Now things have changed, you say. So first of all I must try to install the latest version of Geany. The presently installed version is 0.21.dfsg-1ubuntu4. That appears to be along way behind 1.22, unless someone has dropped the 1, meaning that it would really be 1.21.

     
  • > The presently installed version is 0.21.dfsg-1ubuntu4.
    > That appears to be along way behind 1.22, unless
    > someone has dropped the 1, meaning that it would
    > really be 1.21.

    Actually it's the other way around, 0.22 gained a "1", giving 1.22. Anyway, it's only one version -- but yes, color schemes were enhanced a lot to make it possible to have one single theme file for everything. Gone are they days were one had to modify colors on a per-filetype basis.