Color and Fonts setting for Apex and VF

368 views
Skip to first unread message

Stefan A

unread,
Sep 24, 2015, 5:55:24 AM9/24/15
to Illuminated Cloud General Discussion
I need it sooo much.

Scott Wells

unread,
Sep 24, 2015, 9:15:50 AM9/24/15
to Illuminated Cloud General Discussion
Added an enhancement request to the issue tracker for dedicated Colors and Fonts settings:


Regards,
Scott

Scott Wells

unread,
Sep 24, 2015, 9:56:54 AM9/24/15
to Illuminated Cloud General Discussion
Oh, and I just added this to the logged issue, but you can actually do this today by configuring the colors/fonts settings for Java and HTML respectively.  Here's a screenshot of Apex and Visualforce under IntelliJ's Darcula theme:


You can adjust this to match your own preferences by playing with the settings for Java and HTML until I address issue #117 and add dedicated settings for Apex and VF.

Stefan A

unread,
Sep 24, 2015, 9:59:47 AM9/24/15
to Illuminated Cloud General Discussion
Good point, but it would be nice to have it out of the box.

Scott Wells

unread,
Sep 24, 2015, 10:03:39 AM9/24/15
to Illuminated Cloud General Discussion
Yup, totally agreed.  Explicit configuration settings for the IC-specific languages is a definite plus if for no other reason than the piggy-back relationship with Java/HTML isn't intuitively obvious.  It's actually quite an easy feature to add, so I'll likely look at it after I knock out the metadata deployment/retrieval enhancements for 1.6 as I'm adding Lightning support in 1.7.  That seems like as good a time as any given that I'm going to be adding broad support for a new framework anyway.  Appreciate the feedback!

koen...@gmail.com

unread,
May 9, 2016, 3:37:51 PM5/9/16
to Illuminated Cloud General Discussion
Just giving Illuminated a try here - it annoys me greatly that variables have the same color as the preceding type - messing around with the Java colour scheme does not seem to be able to resolve this - any timeline for a resolution? If only I could pull-request it in!

Scott

unread,
May 9, 2016, 4:07:19 PM5/9/16
to Illuminated Cloud General Discussion
I'm not 100% sure I follow the comment "variables have the same color as the preceding type".  Are you looking for types in general to be styled differently from declared variables, primitive types in particular, or something else?  I've tried to follow IntelliJ IDEA's Java styling closely here where (non-primitive) types and variables are both styled as identifiers.  Variables may have some additional styling applied based on modifiers, e.g., static and/or final, or if they're member variables vs. local/stack variables.  In early releases I styled primitives as keywords, but in Apex even primitive types are actually classes that extend the common Object base class, I changed to make them styled as type identifiers.

Anyway, not trying to dismiss/dispute the comment...just trying to understand it better.  As for a timeframe for Apex-specific colors & fonts settings, let me wrap up the Lightning enhancements and I'll take a look.  My guess is that it's just a few days of work to get it done and it's definitely a recurring request.

Regards,
Scott

koen...@gmail.com

unread,
May 9, 2016, 4:26:43 PM5/9/16
to Illuminated Cloud General Discussion
I am not a IDEA-user at all normally - that might be reason for the annoyance, but I guess that I'm not the only Force.com developer with another background.

Consider the following example I just stumbled upon:

I am referencing another class which has a custom defined type I am trying to use locally - while scrolling over lines of code like this it would be very nice to see both the fact that I am referencing another class (distinction in same other/file would be awesome but a secondary wish) and clearly being able to identify all my local variable names by them having the same colour - now all of it is mono-tone which makes it pretty intensive to comprehend without going into line-level detail. My current primary editor (MM + Atom) shows situations like this as:


Which isn't how I would ideally see things either - but so far hasn't drawn enough of my attention to look for the colour options at all.


Anyway, no rush, I was just surprised to find a quite sophisticated Force.com-capable editor and then conclude that it makes skipping through my code somewhat more difficult.


I have some more feedback so far - but will look around if there are other issues mentioning these.

Scott

unread,
May 9, 2016, 6:37:32 PM5/9/16
to Illuminated Cloud General Discussion
Gotcha.  Yeah, that's just because I modeled it after the IntelliJ IDEA Java editor behavior which looks like the following:


You can see that non-primitive type and variable names are both styled identically as identifiers, and primitive type names are styled as keywords.

When I do get to this work, I'm not at all opposed to having a separate setting for type names in Apex that defaults to the same as other identifiers but can be configured separately.  I'm honestly a little surprised that JetBrains doesn't already offer such a distinction.

Scott

unread,
May 10, 2016, 11:18:23 AM5/10/16
to Illuminated Cloud General Discussion
I've updated the enhancement issue with the request for distinct styling of type names:


Reply all
Reply to author
Forward
0 new messages