[Geany-Users] Editor customization Q?

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Geany-Users] Editor customization Q?

R. Mariotti
As my eyes get older and more tired I am having difficulty seeing the
differences between a single quote and double quote characters.

Might there be a tweak to the editor to display each in a different
color than the other text?  Might help my from becoming blind before my
time.

Also, is there any other suggestion for accomplishing something similar?

Thanks

ps:  I still use v 1.22

_______________________________________________
Users mailing list
[hidden email]
https://lists.geany.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: [Geany-Users] Editor customization Q?

Lex Trotman
On 25 April 2016 at 06:01, R.Mariotti <[hidden email]> wrote:
> As my eyes get older and more tired I am having difficulty seeing the
> differences between a single quote and double quote characters.

There is no way of having the different quotes different colours.  It
would require special code in the upstream Scintilla editing widget
that does the syntax detection for highlighting.  I doubt it would be
accepted.

>
> Might there be a tweak to the editor to display each in a different color
> than the other text?  Might help my from becoming blind before my time.
>
> Also, is there any other suggestion for accomplishing something similar?

Try changing font or size.

>
> Thanks
>
> ps:  I still use v 1.22
>
> _______________________________________________
> Users mailing list
> [hidden email]
> https://lists.geany.org/cgi-bin/mailman/listinfo/users
_______________________________________________
Users mailing list
[hidden email]
https://lists.geany.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: [Geany-Users] Editor customization Q?

John Yeung
On Sun, Apr 24, 2016 at 7:49 PM, Lex Trotman <[hidden email]> wrote:
> On 25 April 2016 at 06:01, R.Mariotti <[hidden email]> wrote:
>> As my eyes get older and more tired I am having difficulty seeing the
>> differences between a single quote and double quote characters.
>
> There is no way of having the different quotes different colours.  It
> would require special code in the upstream Scintilla editing widget
> that does the syntax detection for highlighting.  I doubt it would be
> accepted.

Well, there is clearly *something* in Scintilla that can distinguish
between the two quote characters, because the C/C++ and Python lexers
for SciTE have single-quotes as a separate style from double-quotes.
(No doubt other lexers do as well, but I have personally used those
two.)

So if it is difficult to add to Geany, it is due to design decisions
within Geany. I'm not saying Geany has a bad design, or that Scintilla
makes it easy. I just know that it is possible with Scintilla.

John Y.
_______________________________________________
Users mailing list
[hidden email]
https://lists.geany.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: [Geany-Users] Editor customization Q?

Lex Trotman
On 25 April 2016 at 14:00, John Yeung <[hidden email]> wrote:

> On Sun, Apr 24, 2016 at 7:49 PM, Lex Trotman <[hidden email]> wrote:
>> On 25 April 2016 at 06:01, R.Mariotti <[hidden email]> wrote:
>>> As my eyes get older and more tired I am having difficulty seeing the
>>> differences between a single quote and double quote characters.
>>
>> There is no way of having the different quotes different colours.  It
>> would require special code in the upstream Scintilla editing widget
>> that does the syntax detection for highlighting.  I doubt it would be
>> accepted.
>
> Well, there is clearly *something* in Scintilla that can distinguish
> between the two quote characters, because the C/C++ and Python lexers
> for SciTE have single-quotes as a separate style from double-quotes.
> (No doubt other lexers do as well, but I have personally used those
> two.)

Scintilla is identifying the string (") and character (') quoted
lexical entities, which includes their contents, its not just the " or
' characters.  These entities are available for separate highlighting
as complete entities under the "string" and 'character' names, but you
cannot change the colour of the quotes characters separately, which is
what you asked for.

If you want to change the whole entity see the manual for how to edit
the colour schemes, or just edit the scheme you are using, its pretty
obvious.

>
> So if it is difficult to add to Geany, it is due to design decisions
> within Geany. I'm not saying Geany has a bad design, or that Scintilla
> makes it easy. I just know that it is possible with Scintilla.
>
> John Y.
> _______________________________________________
> Users mailing list
> [hidden email]
> https://lists.geany.org/cgi-bin/mailman/listinfo/users
_______________________________________________
Users mailing list
[hidden email]
https://lists.geany.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: [Geany-Users] Editor customization Q?

John Yeung
On Mon, Apr 25, 2016 at 12:29 AM, Lex Trotman <[hidden email]> wrote:
> Scintilla is identifying the string (") and character (') quoted
> lexical entities, which includes their contents, its not just the " or
> ' characters.  These entities are available for separate highlighting
> as complete entities under the "string" and 'character' names, but you
> cannot change the colour of the quotes characters separately, which is
> what you asked for.

I didn't ask for anything. But I figured highlighting single-quoted
strings differently than double-quoted ones would be a benefit to the
person who did. So if Geany can do it, then that is what I would
recommend to OP.

John Y.
_______________________________________________
Users mailing list
[hidden email]
https://lists.geany.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: [Geany-Users] Editor customization Q?

Lex Trotman
On 25 April 2016 at 16:01, John Yeung <[hidden email]> wrote:
> On Mon, Apr 25, 2016 at 12:29 AM, Lex Trotman <[hidden email]> wrote:
>> Scintilla is identifying the string (") and character (') quoted
>> lexical entities, which includes their contents, its not just the " or
>> ' characters.  These entities are available for separate highlighting
>> as complete entities under the "string" and 'character' names, but you
>> cannot change the colour of the quotes characters separately, which is
>> what you asked for.

Ok, "the OP asked for".

>
> I didn't ask for anything. But I figured highlighting single-quoted
> strings differently than double-quoted ones would be a benefit to the
> person who did. So if Geany can do it, then that is what I would
> recommend to OP.
>
> John Y.
> _______________________________________________
> Users mailing list
> [hidden email]
> https://lists.geany.org/cgi-bin/mailman/listinfo/users
_______________________________________________
Users mailing list
[hidden email]
https://lists.geany.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: [Geany-Users] Editor customization Q?

Colomban Wendling
In reply to this post by R. Mariotti
Le 24/04/2016 à 22:01, R.Mariotti a écrit :
> As my eyes get older and more tired I am having difficulty seeing the
> differences between a single quote and double quote characters.
>
> Might there be a tweak to the editor to display each in a different
> color than the other text?  Might help my from becoming blind before my
> time.
>
> Also, is there any other suggestion for accomplishing something similar?

As Lex pointed out, it's not currently doable by simple means, but there
are a few possible solutions I can think of (that require some work, but
not necessarily so hard)

* Use a font with very distinguishable quotes.  That's the most logical
solution: if the characters are hard to distinguish, fix that.  Such a
font might or might not already exist, so you might have to modify a
font for that or not, I don't know.  But that would benefit all your
usage for this font, not only Geany's.

* Write a tiny plugin adding some indicators
(http://www.scintilla.org/ScintillaDoc.html#Indicators) on quotes so
they have additional visual differences.  It should be fairly easy to do
the obvious way, but do need a little programming work.  It should be
similar to existing plugins proposing highlighting the selected word if
somebody needs some inspiration or basis (as it's free software, hack
it, fork it, or whatever, have fun :).

Hope this can help,
Colomban
_______________________________________________
Users mailing list
[hidden email]
https://lists.geany.org/cgi-bin/mailman/listinfo/users
Loading...