simurai / duotone-dark-syntax

DuoTone dark - A syntax theme for Atom
MIT License
273 stars 22 forks source link

Add more language support #2

Closed braver closed 9 years ago

braver commented 9 years ago

This is going to take some work. I might even abandon this and try again later. I'll run back through my commits and do some before and after screenshots, but for some language features it's hard to do it right without changing the base a bit. Or as I said I'm seeing it wrong and I need to try again.

For now though, the checklist in no particular order:

braver commented 9 years ago

Also, about the separate small files, I'm not seeing a performance hit. The themes files are compiled and cached and those caches probably aren't refreshed very often. So I think it's fine to split them up in really small files.

simurai commented 9 years ago

Wow.. that's a long list of languages. Do you know them all?

Feel free to move the base stuff around. It made sense initially for HTML, CSS, Less.. but maybe not for the rest.

braver commented 9 years ago

No, sadly I don't know them all (I get to about 12 of that list). But I've been doing syntax themes for Sublime for years, so I have some notion of what to look for. And it's usually the grammar definitions that are the limiting factor anyway.

braver commented 9 years ago

@simurai With regards to LESS/CSS/SCSS, you're now making all selectors white. I'm wondering:

  1. We could subdue tags a bit so classes stand out more. That would give some structure to the selectors.
  2. We could differentiate mixins from regular selectors.

I'm not 100% sure either way, I really like the basic simplicity of the theme as is. What do you think?

simurai commented 9 years ago
  1. Hmm.. I also like its simplicity and not sure if having a different color between tags vs classes is necessarily better.
  2. Yeah, that might be a good idea. Mostly because in Less the mixins look like selectors and makes it confusing and harder to find. Not sure what color though.. currently there are just 4 levels of purple. "white" being just a very bright purple. So it might could be an "almost white"?

btw. the duo-3 color isn't used anywhere.. I just added it to have 4 colors for each. Maybe we can remove it for now and just add it if we really need a 4th duo color.

braver commented 9 years ago

Hmm.. I also like its simplicity and not sure if having a different color between tags vs classes is necessarily better.

Agreed

Yeah, that might be a good idea. Mostly because in Less the mixins look like selectors and makes it confusing and harder to find.

I've definitely had to look twice a few times because of that. I'll look into it and try to pick a color that makes sense.

btw. the duo-3 color isn't used anywhere.. I just added it to have 4 colors for each. Maybe we can remove it for now and just add it if we really need a 4th duo color.

Yeah, I noticed. If I haven't found a use for it by the end of the week it's going out :wink:

braver commented 9 years ago

uno-2 seems like the subtle option. Gets a bit lots in a sea of variables depending on what your stylesheet looks like. Not sure if that's a problem, at least it doesn't look like a selector. screen shot 2015-03-31 at 23 35 50

I like it with duo-2 too though. This is otherwise only used for units, so mixins really stand out. And I like that because usually a mixin is actually kinda special. screen shot 2015-03-31 at 23 36 14

What do you think?

simurai commented 9 years ago

I agree on using duo-2 for mixins. yeah, uno-2 get's lost a bit.. and adding a 5th uno color (uno-1.5) might be too hard to tell them apart.

braver commented 9 years ago

Done deal

simurai commented 9 years ago

Ok, duo-3 has to go.. :grimacing: I played around with a logo and 7 shades work perfectly:

duotone-dark 1x

simurai commented 9 years ago

Ooops.. I guess updating the README broke the auto-merge.

braver commented 9 years ago

That logo is so cool!

braver commented 9 years ago

I'm actually pretty happy with this in its current state, for the language I have to live with daily. What's still a "problem" though is that we default to uno-4 for source. That means that for very limited language packages like that for javascript or shell scripts, a lot of text is very subdued. I now resolve that per language by going to uno-2. Which is a bit inelegant. Other syntax themes don't tend to deal with lacking grammars any more gracefully though.

braver commented 9 years ago

@simurai I checked everything off, checking mostly if it looks ok without adding too much detail/complexity. Would love to get your feedback on this and see if there's anything left to tweak before merging this.

simurai commented 9 years ago

Awesome! Yeah, let's merge it. Looks good for the languages that I use too.

Right, uno-4 for source is a bit unfortunate. There is no way around it unless updating the grammars to add extra selectors, right?

Maybe an option would be to do:

@syntax-text: @uno-2; // colors.less

// _base.less
.meta {
  .uno-4();
}

So the default text color (for any unknown language) is uno-2 and then for the languages that we support/control add the uno-4 back.

.css {
  &.source {
    .uno-4();
  }
}

Would have higher specificity which might messes up some stuff. Would have to try.

simurai commented 9 years ago

I still have this https://github.com/atom/atom/issues/5903 issue pinned in my browser. Would be so cool to easily change the uno/duo colors without forking the whole theme.

"Salmon On Ice": screen shot 2015-04-15 at 3 50 18 pm