Skip to content

Commit 8338b02

Browse files
authored
feat: no_underline option (#489)
* feat: `no_underline` option * docs: auto generate vimdoc --------- Co-authored-by: mrtnvgr <[email protected]>
1 parent 57b421e commit 8338b02

File tree

6 files changed

+8
-7
lines changed

6 files changed

+8
-7
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,7 @@ require("catppuccin").setup({
104104
},
105105
no_italic = false, -- Force no italic
106106
no_bold = false, -- Force no bold
107+
no_underline = false, -- Force no underline
107108
styles = {
108109
comments = { "italic" },
109110
conditionals = { "italic" },

doc/catppuccin.txt

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ Table of Contents *catppuccin-table-of-contents*
3030
==============================================================================
3131
1. Features *catppuccin-features*
3232

33-
3433
- Supports both vim and neovim (Requires neovim <https://github.com/neovim/neovim/> >= 0.8 or vim <https://github.com/vim/vim> >= 9 compiled with lua <https://github.com/lua/lua> >= 5.1)
3534
- Highly configurable with 4 different flavours and ability to create your own! <https://github.com/catppuccin/nvim/discussions/323>
3635
- Compile <https://github.com/catppuccin/nvim#Compile> user config for fastest startuptime <https://www.reddit.com/r/neovim/comments/xxfpt3/catppuccinnvim_now_startup_in_1ms/>
@@ -95,6 +94,7 @@ options and settings.
9594
},
9695
no_italic = false, -- Force no italic
9796
no_bold = false, -- Force no bold
97+
no_underline = false, -- Force no underline
9898
styles = {
9999
comments = { "italic" },
100100
conditionals = { "italic" },
@@ -134,7 +134,6 @@ GENERAL *catppuccin-configuration-general*
134134

135135
This settings are unrelated to any group and are independent.
136136

137-
138137
- `background`: (Table) Match :set background=light/dark with :Catppuccin background.light/dark
139138
- `term_colors`: (Boolean) if true, sets terminal colors (e.g. `g:terminal_color_0`).
140139
- `transparent_background`: (Boolean) if true, disables setting the background color.
@@ -145,7 +144,6 @@ DIM INACTIVE *catppuccin-configuration-dim-inactive*
145144
This setting manages the ability to dim the inactive splits/windows/buffers
146145
displayed.
147146

148-
149147
- `enabled`: (Boolean) if true, dims the background color of inactive window or buffer or split.
150148
- `shade`: (string) sets the shade to apply to the inactive split or window or buffer.
151149
- `percentage`: (number 0 < x < 1) percentage of the shade to apply to the inactive window, split or buffer.
@@ -155,7 +153,6 @@ STYLES *catppuccin-configuration-styles*
155153

156154
Handles the style of general hi groups (see `:h highlight-args`):
157155

158-
159156
- `comments`: (Table) changed the style of the comments.
160157
- `functions`: (Table) changed the style of the functions.
161158
- `keywords`: (Table) changed the style of the keywords.
@@ -1033,13 +1030,11 @@ COLORS DOESN’T MATCH PREVIEW SCREENSHOTS*catppuccin-faq-colors-doesn’t-match
10331030
Catppuccin requires true color support AKA terminals support the full range of
10341031
16 million colors
10351032

1036-
10371033
- Supported: iterm2 (macOS), kitty, wezterm, alacritty, tmux, …
10381034

10391035
Full list of support terminals can be found here:
10401036
<https://github.com/termstandard/colors#truecolor-support-in-output-devices>
10411037

1042-
10431038
- Unsupported terminal: Terminal.app (macOS), Terminus, Terminology, …
10441039

10451040
Full list of Unsupported terminals can be found here:
@@ -1049,7 +1044,6 @@ Full list of Unsupported terminals can be found here:
10491044
==============================================================================
10501045
9. Thanks to *catppuccin-thanks-to*
10511046

1052-
10531047
- Pocco81 <https://github.com/Pocco81>
10541048
- nullchilly <https://github.com/nullchilly>
10551049

lua/catppuccin/init.lua

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ local M = {
1818
},
1919
no_italic = false,
2020
no_bold = false,
21+
no_underline = false,
2122
styles = {
2223
comments = { "italic" },
2324
conditionals = { "italic" },

lua/catppuccin/lib/compiler.lua

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ local h = vim.api.nvim_set_hl]],
5151
color[style] = true
5252
if O.no_italic and style == "italic" then color[style] = false end
5353
if O.no_bold and style == "bold" then color[style] = false end
54+
if O.no_underline and style == "underline" then color[style] = false end
5455
end
5556
end
5657
color.style = nil

lua/catppuccin/lib/vim/compiler.lua

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ let g:colors_name = "catppuccin-%s"]],
4343
for _, style in pairs(color.style) do
4444
if O.no_italic and style == "italic" then style = nil end
4545
if O.no_bold and style == "bold" then style = nil end
46+
if O.no_underline and style == "underline" then style = nil end
4647
if style then rstyle[#rstyle + 1] = style end
4748
end
4849
color.style = table.concat(rstyle, ",")

vim.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,9 @@ globals:
165165
O.no_bold:
166166
type: bool
167167
property: read-only
168+
O.no_underline:
169+
type: bool
170+
property: read-only
168171

169172
O.styles.comments:
170173
type: table

0 commit comments

Comments
 (0)