Giter VIP home page Giter VIP logo

Comments (7)

cocopon avatar cocopon commented on August 27, 2024

I think that consistency is important too.

About Vim function, it's my mistake 😅

Vim function is linked to Statement (it's blue in Iceberg) group by default: vimFuncKey -> vimCommand -> Statement
So it is displayed in blue color. I'll fix it later!

Sending PR or creating issue about inconsistency is welcome :)

from iceberg.vim.

pkazmier avatar pkazmier commented on August 27, 2024

I submitted #32 to fix.

from iceberg.vim.

pkazmier avatar pkazmier commented on August 27, 2024

As I've been trying to normalize the syntax highlighting across several languages, I'm torn on whether or not function invocations should be highlighted. What do you think? To give a concrete example, here is a screenshot of Go code normalized using your guidelines (as I have interpreted them):

screen shot 2018-07-01 at 12 39 02 pm

And here is an alternate version where I experimented with highlighting function invocations and changing variable definitions to green to make them easy to spot:

screen shot 2018-07-01 at 12 39 39 pm

Function invocation highlighting is beneficial when you have a series of function calls within function calls such as:

rand.Seed(time.Now().Unix()) 

From a legibility point of view, it makes it much easier to read code. The only problem is if I use cyan for this function invocation, then there is too much cyan, which require tweaking maybe the color of variable definitions to green perhaps as shown in the alternate version above.

I would be very appreciative of your opinion on the matter as it would impact the PR I've submitted.

from iceberg.vim.

cocopon avatar cocopon commented on August 27, 2024

As a first step, I re-organized whole highlighting rules in b688907.
Because your changes and mine affect too wide range, I can't merge them...really sorry 😢

from iceberg.vim.

cocopon avatar cocopon commented on August 27, 2024

After much thought, I carefully resolved conflicts and merged your changes (#32) to the latest files. In the process, I modified some definitions in terms of consistency:

  • jsDestructuringBlock should be highlighted as Normal (same as other variables)

  • jsFuncArgs, jsVariableDef should be highlighted as Normal (same as other languages)

  • jsTemplateExpression should be highlighted as Normal (because it should be highlighted as same as normal expressions)

    // Example: `foo` should be highlighted as `Normal`
    `${foo['bar']}`

Feel free to reopen the issue if there are any problems.

from iceberg.vim.

cocopon avatar cocopon commented on August 27, 2024

Ah I forgot to reply your suggestion, sorry...

From a legibility point of view, it makes it much easier to read code. The only problem is if I use cyan for this function invocation, then there is too much cyan, which require tweaking maybe the color of variable definitions to green perhaps as shown in the alternate version above.

As I said in this comment, at the moment, I think that current highlightings have enough readability so using less colors is better. But I am hesitating about which one is really good.

from iceberg.vim.

cocopon avatar cocopon commented on August 27, 2024

Feel free to reopen the issue or create new one if you find new inconsistencies.

from iceberg.vim.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.