-
Notifications
You must be signed in to change notification settings - Fork 90
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
1e638ef
commit 9a8e9db
Showing
1 changed file
with
15 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
|
||
fun! tmuxline#themes#airline_tabline#get() abort | ||
if !has_key(g:, 'airline_theme') | ||
throw "tmuxline: Can't load theme from airline, g:airline_theme isn't defined. Is airline loaded?" | ||
endif | ||
if !has_key(g:, 'airline#themes#' . g:airline_theme . '#palette') | ||
throw "tmuxline: Can't load theme from airline, 'g:airline#themes#" . g:airline_theme . "#palette' isn't defined. Is airline loaded?" | ||
endif | ||
|
||
let mode = 'normal' | ||
let mode_palette = g:airline#themes#{g:airline_theme}#palette[mode] | ||
let theme = tmuxline#util#create_theme_from_airline(mode_palette) | ||
let theme.cwin = mode_palette.airline_a[2:4] | ||
return theme | ||
endfun |