GithubHelp home page GithubHelp logo

romainl / apprentice Goto Github PK

View Code? Open in Web Editor NEW
869.0 12.0 87.0 3.33 MB

A dark, low-contrast, Vim colorscheme.

Home Page: http://romainl.github.io/Apprentice/

License: MIT License

Makefile 1.69% Vim Script 98.31%
vim vim-plugin colorscheme apprentice

apprentice's People

Contributors

djmoch avatar keremc avatar lemonboy avatar lucasprag avatar lunacookies avatar mwcz avatar nogerine avatar romainl avatar rsaihe avatar ubmit avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

apprentice's Issues

Does Vim-Polyglot plugin makes Apprentice better?

It's just a question. I love this colorscheme and I want to know if any Vim plugin for syntax highlighting changes something using this colorscheme? If it doesn't, close my issue. Thanks for the attention!

Vim patch 9.0.0032: Cursorline + QuickFixLine no longer look right together

There's always been a weird interaction between cursor line highlight and QuickFix current line highlight.

Steps to repro:

  • Using vim 9.0.0032 in the vim build directory, run : env VIMRUNTIME=$(pwd)/runtime ./src/vim --clean --cmd 'set rtp+=$HOME/.vim/bundle/Apprentice' --cmd 'colorscheme apprentice' --cmd 'set termguicolors' --cmd 'set cursorline' -c 'grep edit src/edit.c' -c 'copen'
  • ctrl-w j - jump to quick fix
  • see that the cursor line highlight and the quick fix line highlights make the text unreadable.

Screenshot:

Screenshot 2022-07-12 at 15 58 55

Demo showing both current and previous:

https://asciinema.org/a/xxn6mnepdN5qfrYN6GUD8ju9J

vim-airline active pane is orange and non-active tab is orange causing confusion

This has caused a little difficulty for me, I don't know if it is something you have control over because I have not written any themes before myself. It may be entirely a vim-airline thing for all I know.

Non-active tabs are orange but they draw my eye so I always think they're the active one, especially when I have exactly 2 tabs open (the second tab here is actually the active one):
screen shot 2015-06-04 at 5 22 18 pm

Active pane is orange:
screen shot 2015-06-04 at 5 05 33 pm

SpellBad and CursorLine improvement

I mentioned before that hitest.vim didn't work well on my setup, but that I couldn't repro with clean env. I have now reproduced it:

lxlvykz

The key appears to be the addition of set spell, and therefore I guess the SpellBad group.

Steps to repro:

  1. vim -Nu test.vim
  2. source $VIMRUNTIME/syntax/hitest.vim
  3. jjjjjjj (move the cursor)

test.vim:

" Adjust as necessary
set runtimepath+=$HOME/.vim/bundle/Apprentice

set background=dark

" Below required for termguicolors outside of xterm
let &t_8f = "\<Esc>[38:2:%lu:%lu:%lum"
let &t_8b = "\<Esc>[48:2:%lu:%lu:%lum"

set termguicolors

colorscheme apprentice

set cursorline
set textwidth=80
set colorcolumn=+1

set spell

filetype plugin indent on
syn on

I realise that hitest.vim isn't real code and doesn't disable spell highlighting, but I started investigating this because I do have set spell and the red text toggling depending on the cursor position was jarring (I thought it was a setup issue).

In terms of resolution, I'm not totally sure. Colorschemes that I've used before don't use a colour for SpellBad (just the underline) which seems to work well, and doesn't toggle with cursorline, etc. But of course I leave the creative direction to your good self. For example, running hi SpellBad guifg=NONE works well for me :)

Anyway, I hope this report is useful. If not, or it's intentional, feel free to close (no hard feelings :))

cursor line and indent colour

uh I was asking about this on IRC and you asked if you could help but by that time I went to sleep. Anyways http://imgur.com/a/xikcj

In the top picture I'm using cursor line. See how the red is kinda screwed to show the indents?

Then look at the bottom one. I'm not using cursor line and its perfect now. I'd like it to look like the bottom one. Is it possible to fix this?

Use Apprentice with Bat

Hi,

First of all thanks for the theme!
I would like to know if we could use Apprentice with Bat https://github.com/sharkdp/bat.
I don't see any option to export the theme to TextTame thTheme extension (that's the one bat uses).
Maybe we have to port it manually, unfortunately...

Thanks!

not loading anymore in vim 8.0

Since last commit (0e624fd) apprentice refuses to load (at vim startup), unless I set explicitly set background=dark in my vimrc before colorscheme apprentice.

It doesn't happen in nvim or vim 8.1.

Does not load from vimrc (but loads fine manually)

Having colorscheme apprentice in .vimrc will load the default theme (macvim in my case). But when calling :colorscheme apprentice manually as a command, it is loaded fine.

:version
VIM - Vi IMproved 8.2 (2019 Dec 12, compiled Dec 19 2020 21:23:05)
macOS version
Included patches: 1-2164

License

This project lacks a license file. Could you please add a (Free Software/Open Source) license?

Pandoc Equation Conceals look ugly / unreadable

Vim Pandoc and its syntax plugin use a conceal to hide \alpha and other LaTeX equations.

They use highlighting, but under the Apprentice colorscheme, the concealed icons are colored white, with white highlighting making it unreadable as below:
screenshot

Steps to reproduce

  1. :e foobar.md
  2. i $$\alpha$$ <CR>
  3. should show the syntax highlighting if pandoc and its syntax equivalent are installed

Remove special handling for iTerm.app

Not sure of all of the history here, but I assume the reason iTerm is handled differently from other terminal emulators at all is because of some irregularities in it's 256 colorspace. Whatever the reason, the colors look correct to me if the special handling is removed, otherwise they look a bit too dark.

Tested by running iTerm with this color configuration, opening Vim inside a tmux session, and comparing the background color to the border the tmux places around the terminal panes. The colors are a perfect match if the special-case handling for iTerm is removed.

Current iTerm version for me is Build 3.0.13.

gVim cursor foreground color

In gVim text under cursor is barely visible on some syntax highlighted text:

image

image

image

I can fix it in colorscheme event (and I will), but just in case you would like to fix it in your colorscheme:

  hi Cursor guifg=#BCBCBC

[WIP] Diff improvements

This is an effort to come up with better diff colors, suitable for a wider range of users.

function! BetterDiffColors()
    hi DiffAdd ctermfg=111 guifg=#87afff
    hi DiffDelete ctermfg=222 guifg=#ffdf87
    hi DiffChange ctermfg=188 guifg=#dfdfdf
    hi DiffText ctermfg=145 guifg=#afafaf
endfunction
augroup MyDiffColors
    autocmd!
    autocmd Colorscheme apprentice call BetterDiffColors()
augroup END

Normal vision

Capture d’écran 2022-01-18 à 15 07 17

Problems with blue

Blue weakness, tritanomaly

blue-weak tritanomaly

Blue blindness, tritanopia

blue-blind tritanopia

Problems with green

Green weakness, deuteranomaly

green-weak deuteranomaly

Green blindness, deuteranopia

green-blind deuteranopia

Problems with red

Red weakness, tritanomaly

red-weak protanomaly

Red blindness, tritanopia

red-blind protanopia

Monochromacy

TODO

Airline theme

Hi, is there any reason for airline/lightline themes to live in a separate branch? As far as I can see it seems pretty outdated compared to master.

If you do not wish to keep this in master, then maybe merging the airline apprentice theme to https://github.com/vim-airline/vim-airline-themes (do not know if lightline has a similar repo with themes) would be a good idea?

Search and DiffAdd having the same colors can be confusing

When doing a search while in diff mode, the stuff that matches gets highlighted with the same color as additional lines (highlight group DiffAdd). I did find this somewhat confusing, first mistaking the added lines as search matches as well.

Slight color mismatch

The color 12 (light blue) has gui and term colors: #8fafd7 and 110 respectively.
Converting the term color from ansi to rgb, we get: #87afd7. Notice the difference in second hexit from the left.

Is this difference intentional?

support for dark terminal

I use the default terminal app on ubuntu, but have set background color to completely opague black. This makes your theme look rather bad. Cannot see the linenumber or highlighted lines.

On a white background, it looks brilliant though. Any chance this could work for both?

Iterm2 port

Hi,

I really like this theme but i was not able to reproduce the same colors from vim in iterm2 console (using Xresources export tool from terminal.sexy).

does anyone know how to do it?

thanks!

Problem with bold and italic (vimwiki)

On vimwiki bold and italic formatting doesn't work with Apprentice.
Other themes have problems with italic on terminal but they support at least bold formatting.
With Apprentice this is not possible.

Discussion about two thoughts for comments

You opted into the subtle comments. They're nice we all use them etc

But there's this idea out there, Martin Fowler especially talks about it, where comments should stand out and be ugly almost, certainly contrasting

You can use this to gauge if something is commented wrongly, because you just see a ton of comments. It may feel wrong

A more contrasted comment w/ Apprentice may look like:

image

or

image

I don't expect this to become a thing, I mostly wanted it documented here so I can refer others to the idea

The changes would look like:

function! LouderComments() abort
  highlight Comment ctermbg=131 ctermfg=231
  highlight Todo ctermbg=131 ctermfg=231 cterm=reverse
endfunction

augroup Apprentice
  autocmd!
  autocmd ColorScheme * call LouderComments()
augroup END


colorscheme apprentice

Vscode theme port

hi guys i did not find anything related to a port for vscode.
does anyone knows how to do it somehow?

cheers

debugPC highlight group

:Termdebug comes with a feature to insert breakpoints in vim from the editor.

According to the manual, the sign used in the sidebar to show breakpoints is in the highlight group "debugBreakpoint".

For the time being, there is apparently no specific setting for this group, and the "default" I get is Foreground fg with 9 bg in terminal, which is pretty ugly. I think the normal red would be better as a background.

Also, there is a "debugPC" highlight group, which shows the current debugged line in the vim window. The default I get is just a 4 or 12 (I'd say 12) bg on the normal text, which can be a little hard to read with the type keywords being purple.

I don't really know what colours would be good here, hopefully you'll have better taste than me.

EDIT : This may be a terminal colorscheme issue, because it doesn't show at all in the asciinema I uploaded ( here ). The red is a lot darker here than on my laptop. The blue is not exactly the same either, but the readability is still not optimal

FYI: bug filed with Vim upstream

I don't think this is related to Apprentice, because I happens with Solarized Light and Solarized Dark and a couple others I've tried, so I filed an issue on Vim: vim/vim#10347

The reason I mention it here is because I used Apprentice as the example, and maybe you've come across this issue? I noticed there was some cterm fix for win32 recently that might somehow be related?

Guard setting g:terminal_ansi_colors for <=256 colors terminal emulators

I'm using the latest MacVim which also provides a /Applications/MacVim.app/Contents/bin/vim TUI version. The issue is that on Terminal.app using that TUI when we open a :term the colors are off because even though :version reports '+termguicolors' Terminal.app cannot do that. My suggestion would be to guard setting the ansi colors somehow. I have Terminal.app using the Apprentice palette as well, that's how I noticed the difference when opening a terminal buffer (blue becomes purple-y)
For now, I've just commented out the defined terminal ansi colors in apprentice.vim and let my terminal palette (set to Apprentice) handle it. I'm not sure how you'd fix it, I first thought about adding:

if has('termguicolors')
...
endif

But in my example above it would still pass. Maybe you'd have to do something like:

if has('termguicolors') && !$TERM_PROGRAM =~# 'Apple_Terminal'
...
endif

But then you might end up having to add a bunch of exceptions like this.

Comments too dark.

Hi, I realize colorscheme is mostly a taste thing, so no problems in closing this. Couldn't you set comments a bit brighter? I'm trying this colorscheme and it's quite nice except for this, I've tried it in two displays, a macbook and a LCD, in both the comments are a bit difficult to distinguish from background.

Thanks.

Request: Set terminal ansi colors even when 'notermguicolors' set

if (has('termguicolors') && &termguicolors) || has('gui_running')

Situation which prompted this: I was trying out the newest MacVim release (9.0 support!), and when I started a :term noticed that the colors weren't the apprentice palette - the reason being that I had 'set notermguicolors' set. Is it possible since appentice picks from the 'standard' xterm 256 palette though, that if we have don't have 'termguicolors' set but we either have 256 or GUI then we still set the ansi terminal colors to apprentice palette? Should be fine for GUI but for Terminal.app without profile set to apprentice colours, I'm not sure if it would work? I tried changing profile to Basic on Terminal.app and apprentice still seems to work exactly the same in vim.

Screen Shot 2022-07-25 at 8 53 24 AM

distribute with Vim

As discussed on reddit:
there is an issue open in the vim repository, to distribute more colorschemes with Vim. Would you kindly give your permission to distribute this colorscheme with Vim?

New parens matching color is breaking my brain

I updated to the latest Apprentice 3 days ago, and for 3 days I've been constantly confused about where my cursor is when dealing with matching parens. I rolled back to see what the difference was. When the matching was white, the opposite paren lit up enough that I would lock onto it. Now that they're a tan brown, the change in the paren is so subtle, that I immediately lock onto the matching paren, highlighted in brown, and my brain tells me that now I'm there. This effect is worse when the parens are near each other - a few characters apart - I feel like I just jumped to the opposite side, and I instantly start hitting motions and commands as though I'm there. For 3 days I've been confused like this and making one error after another. I can always override it, but I thought I'd mention it, as it's an actual issue I'm running into over and over. I didn't even know colors could do this to my head. Would #FFFFAF (also in the palette) be an acceptable alternative?

Theme not displaying properly in tmux with termguicolors enabled

Per your request, this is a copy of my question on StackExchange.

As far as my setup is concerned, I'm running Tmux 2.2 (with true color support enabled) inside iTerm2 version 3 on a Mac. Others have asked questions about similar symptoms on StackExchange, but none of the offered solutions (ttyfast or set t_ut=) fix the issue for me unless I turn termguicolors off.

Here's what I see when I run Vim in iTerm2 directly. Everything looks as I expect:
screen shot 2016-06-07 at 5 22 21 am

But I end up with strange background issues when I run inside Tmux:
screen shot 2016-06-07 at 5 23 09 am

Now the colors are pretty close, so it might be hard to see, but it's actually very jarring when I'm running full screen with split panes and lots of text.

To my eye it looks like the text background color is rendering correctly, and the background color for blank lines renders correctly, but for some reason the background color past the end of the text renders incorrectly. This is probably consistent with other similar questions I've seen.

Here's a picture showing what I mean. Blank lines also render the background color correctly:
screen shot 2016-06-07 at 5 37 39 am

As another data point, I ran set termcap to dump the terminal settings and verified that everything matches between when I run Vim in iTerm vs when I run in Tmux.

Some additional details:

  1. The theme always works in Neovim (v0.1.4), whether I run in Tmux or in iTerm directly. This leads me to believe it is not an issue with your theme.
  2. The terminal in Tmux is set to screen-256-color. Because of limitations in the way Vim handles termguicolors, I end up having to manually set t_8f and t_8b values.

Let me know if you're able to figure anything out!

Idea: link CurSearch to IncSearch

I have trouble with current highlight figuring out which match I'm currently on, especially with a light cursor against a yellow background. I link CurSearch to IncSearch so that I can see exactly which one I'm currently on (with vim-cool). What do you think?

hi! link CurSearch Search Hard to see where cursor currently is:
Screen Shot 2022-05-02 at 10 54 53 AM

hi! link CurSearch IncSearch Now I can tell:
Screen Shot 2022-05-02 at 10 55 13 AM

Would linking CurSearch to IncSearch be a better default? I'm not too familiar with colorscheme stuff in Vim, so I don't know how setting this link would affect other things.

Apprentice breaks loading of color schemes

It appears that Apprentice breaks the loading of color schemes. Once the color scheme is set to Apprentice, any color scheme that is loaded subsequently is "broken" in the sense that some aspects of the highlighting are lost.
I have observed this behaviour for other more complex color schemes (e.g. Solarized or Gruvbox) as well, but it certainly does not happen for all color schemes.
Is there anything that can be done to prevent this?

ModeMsg groups unreadable with cursorline

Hi,

Thanks for the wonderful color scheme :)
I found that text highlighted with ModeMsg is almost invisible when the cursor line (:set cursorline) is over it. For the minimal example, save the following as CMakeLists.txt:

cmake_minimum_required(VERSION 3.0)

AUR package added and request

I made a package in the AUR for Arch users if you want to include that in the installation page of the readme. https://aur.archlinux.org/packages/vim-apprentice/

also: just a request to please keep the format for the filenames of the releases similar since it makes it easier to update the package (currently it's changed between lowercase "apprentice-1.7" to uppercase, using a period "Apprentice.1.8" and uppercase, hyphen "Apprentice-1.9"). thanks :)

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.