You are not logged in.

#26 2024-10-20 11:53:25

seth
Member
Registered: 2012-09-03
Posts: 59,024

Re: Why nvim processes colors differently?

Am I getting this right?

Yes.
You want to know whether st or the vim colorscheme acti differently across the systems.

Also

seth wrote:

Remove the alpha patch, test again.

Offline

#27 2024-10-21 11:54:17

b42
Member
Registered: 2023-07-20
Posts: 189

Re: Why nvim processes colors differently?

Xterm on the old system:

https://ibb.co/02Qb6yq

Colorscheme desert in st on the old system:

https://ibb.co/2vvLFPX

------------------------------------------------------------------

Xterm on the new system:

https://ibb.co/zhNyRh2

Colorscheme desert in st on the new system:

https://ibb.co/d6mFTpV

Last edited by b42 (2024-10-21 12:00:31)

Offline

#28 2024-10-21 12:16:43

seth
Member
Registered: 2012-09-03
Posts: 59,024

Re: Why nvim processes colors differently?

Those are equivalent, so it's either about your alpha patch (doesn't seem to apply here?) or the specific color scheme you originally were concerned about.

Offline

#29 2024-10-21 12:24:52

b42
Member
Registered: 2023-07-20
Posts: 189

Re: Why nvim processes colors differently?

colorscheme is sourced from this file:

vim.cmd.highlight('clear')
vim.g.colors_name = 'vim'

local hi = function(name, val)
  -- Force links
  val.force = true

  -- Make sure that `cterm` attribute is not populated from `gui`
  val.cterm = val.cterm or {}

  -- Define global highlight
  vim.api.nvim_set_hl(0, name, val)
end

--stylua: ignore start
-- General
hi('Normal', {})

hi('Conceal',      { fg = 'LightGrey', bg = 'DarkGrey', ctermfg = 'LightGrey', ctermbg = 'DarkGrey' })
hi('Cursor',       {})
hi('lCursor',      {})
hi('DiffText',     { bg = 'Red', bold = true,           ctermbg = 'Red', cterm = { bold = true } })
hi('ErrorMsg',     { fg = 'White', bg = 'Red',          ctermfg = 'White', ctermbg = 'DarkRed' })
hi('IncSearch',    { reverse = true,                    cterm = { reverse = true } })
hi('ModeMsg',      { bold = true,                       cterm = { bold = true } })
hi('NonText',      { fg = 'Blue', bold = true,          ctermfg = 'Blue' })
hi('PmenuSbar',    { bg = 'Grey',                       ctermbg = 'Grey' })
hi('StatusLine',   { reverse = true, bold = true,       cterm = { reverse = true, bold = true }})
hi('StatusLineNC', { reverse = true,                    cterm = { reverse = true } })
hi('TabLineFill',  { reverse = true,                    cterm = { reverse = true } })
hi('TabLineSel',   { bold = true,                       cterm = { bold = true } })
hi('TermCursor',   { reverse = true,                    cterm = { reverse = true } })
hi('WinBar',       { bold = true,                       cterm = { bold = true } })
hi('WildMenu',     { fg = 'Black', bg = 'Yellow',       ctermfg = 'Black', ctermbg = 'Yellow' })

hi('VertSplit',      { link = 'Normal' })
hi('WinSeparator',   { link = 'VertSplit' })
hi('WinBarNC',       { link = 'WinBar' })
hi('EndOfBuffer',    { link = 'NonText' })
hi('LineNrAbove',    { link = 'LineNr' })
hi('LineNrBelow',    { link = 'LineNr' })
hi('QuickFixLine',   { link = 'Search' })
hi('CursorLineSign', { link = 'SignColumn' })
hi('CursorLineFold', { link = 'FoldColumn' })
hi('CurSearch',      { link = 'Search' })
hi('PmenuKind',      { link = 'Pmenu' })
hi('PmenuKindSel',   { link = 'PmenuSel' })
hi('PmenuExtra',     { link = 'Pmenu' })
hi('PmenuExtraSel',  { link = 'PmenuSel' })
hi('Substitute',     { link = 'Search' })
hi('Whitespace',     { link = 'NonText' })
hi('MsgSeparator',   { link = 'StatusLine' })
hi('NormalFloat',    { link = 'Pmenu' })
hi('FloatBorder',    { link = 'WinSeparator' })
hi('FloatTitle',     { link = 'Title' })
hi('FloatFooter',    { link = 'Title' })

hi('FloatShadow',          { bg = 'Black', blend=80 })
hi('FloatShadowThrough',   { bg = 'Black', blend=100 })
hi('RedrawDebugNormal',    { reverse = true,             cterm = { reverse = true } })
hi('RedrawDebugClear',     { bg = 'Yellow',              ctermbg = 'Yellow' })
hi('RedrawDebugComposed',  { bg = 'Green',               ctermbg = 'Green' })
hi('RedrawDebugRecompose', { bg = 'Red',                 ctermbg = 'Red' })
hi('Error',                { fg = 'White', bg = 'Red',   ctermfg = 'White', ctermbg = 'Red' })
hi('Todo',                 { fg = 'Blue', bg = 'Yellow', ctermfg = 'Black', ctermbg = 'Yellow' })

hi('String',         { link = 'Constant' })
hi('Character',      { link = 'Constant' })
hi('Number',         { link = 'Constant' })
hi('Boolean',        { link = 'Constant' })
hi('Float',          { link = 'Number' })
hi('Function',       { link = 'Identifier' })
hi('Conditional',    { link = 'Statement' })
hi('Repeat',         { link = 'Statement' })
hi('Label',          { link = 'Statement' })
hi('Operator',       { link = 'Statement' })
hi('Keyword',        { link = 'Statement' })
hi('Exception',      { link = 'Statement' })
hi('Include',        { link = 'PreProc' })
hi('Define',         { link = 'PreProc' })
hi('Macro',          { link = 'PreProc' })
hi('PreCondit',      { link = 'PreProc' })
hi('StorageClass',   { link = 'Type' })
hi('Structure',      { link = 'Type' })
hi('Typedef',        { link = 'Type' })
hi('Tag',            { link = 'Special' })
hi('SpecialChar',    { link = 'Special' })
hi('Delimiter',      { link = 'Special' })
hi('SpecialComment', { link = 'Special' })
hi('Debug',          { link = 'Special' })

hi('DiagnosticError',            { fg = 'Red',                          ctermfg = 1 })
hi('DiagnosticWarn',             { fg = 'Orange',                       ctermfg = 3 })
hi('DiagnosticInfo',             { fg = 'LightBlue',                    ctermfg = 4 })
hi('DiagnosticHint',             { fg = 'LightGrey',                    ctermfg = 7 })
hi('DiagnosticOk',               { fg = 'LightGreen',                   ctermfg = 10 })
hi('DiagnosticUnderlineError',   { sp = 'Red', underline = true,        cterm = { underline = true } })
hi('DiagnosticUnderlineWarn',    { sp = 'Orange', underline = true,     cterm = { underline = true } })
hi('DiagnosticUnderlineInfo',    { sp = 'LightBlue', underline = true,  cterm = { underline = true } })
hi('DiagnosticUnderlineHint',    { sp = 'LightGrey', underline = true,  cterm = { underline = true } })
hi('DiagnosticUnderlineOk',      { sp = 'LightGreen', underline = true, cterm = { underline = true } })
hi('DiagnosticVirtualTextError', { link = 'DiagnosticError' })
hi('DiagnosticVirtualTextWarn',  { link = 'DiagnosticWarn' })
hi('DiagnosticVirtualTextInfo',  { link = 'DiagnosticInfo' })
hi('DiagnosticVirtualTextHint',  { link = 'DiagnosticHint' })
hi('DiagnosticVirtualTextOk',    { link = 'DiagnosticOk' })
hi('DiagnosticFloatingError',    { link = 'DiagnosticError' })
hi('DiagnosticFloatingWarn',     { link = 'DiagnosticWarn' })
hi('DiagnosticFloatingInfo',     { link = 'DiagnosticInfo' })
hi('DiagnosticFloatingHint',     { link = 'DiagnosticHint' })
hi('DiagnosticFloatingOk',       { link = 'DiagnosticOk' })
hi('DiagnosticSignError',        { link = 'DiagnosticError' })
hi('DiagnosticSignWarn',         { link = 'DiagnosticWarn' })
hi('DiagnosticSignInfo',         { link = 'DiagnosticInfo' })
hi('DiagnosticSignHint',         { link = 'DiagnosticHint' })
hi('DiagnosticSignOk',           { link = 'DiagnosticOk' })
hi('DiagnosticDeprecated',       { sp = 'Red', strikethrough = true,    cterm = { strikethrough = true } })

hi('DiagnosticUnnecessary', { link = 'Comment' })
hi('LspInlayHint',          { link = 'NonText' })
hi('SnippetTabstop',        { link = 'Visual' })

-- Text
hi('@markup.raw',       { link = 'Comment' })
hi('@markup.link',      { link = 'Identifier' })
hi('@markup.heading',   { link = 'Title' })
hi('@markup.link.url',  { link = 'Underlined' })
hi('@markup.underline', { link = 'Underlined' })
hi('@comment.todo',     { link = 'Todo' })

-- Miscs
hi('@comment',     { link = 'Comment' })
hi('@punctuation', { link = 'Delimiter' })

-- Constants
hi('@constant',          { link = 'Constant' })
hi('@constant.builtin',  { link = 'Special' })
hi('@constant.macro',    { link = 'Define' })
hi('@keyword.directive', { link = 'Define' })
hi('@string',            { link = 'String' })
hi('@string.escape',     { link = 'SpecialChar' })
hi('@string.special',    { link = 'SpecialChar' })
hi('@character',         { link = 'Character' })
hi('@character.special', { link = 'SpecialChar' })
hi('@number',            { link = 'Number' })
hi('@boolean',           { link = 'Boolean' })
hi('@number.float',      { link = 'Float' })

-- Functions
hi('@function',                   { link = 'Function' })
hi('@function.builtin',           { link = 'Special' })
hi('@function.macro',             { link = 'Macro' })
hi('@function.method',            { link = 'Function' })
hi('@variable.parameter',         { link = 'Identifier' })
hi('@variable.parameter.builtin', { link = 'Special' })
hi('@variable.member',            { link = 'Identifier' })
hi('@property',                   { link = 'Identifier' })
hi('@attribute',                  { link = 'Macro' })
hi('@attribute.builtin',          { link = 'Special' })
hi('@constructor',                { link = 'Special' })

-- Keywords
hi('@keyword.conditional', { link = 'Conditional' })
hi('@keyword.repeat',      { link = 'Repeat' })
hi('@keyword.type',        { link = 'Structure' })
hi('@label',               { link = 'Label' })
hi('@operator',            { link = 'Operator' })
hi('@keyword',             { link = 'Keyword' })
hi('@keyword.exception',   { link = 'Exception' })

hi('@variable',          { link = 'Identifier' })
hi('@type',              { link = 'Type' })
hi('@type.definition',   { link = 'Typedef' })
hi('@module',            { link = 'Identifier' })
hi('@keyword.import',    { link = 'Include' })
hi('@keyword.directive', { link = 'PreProc' })
hi('@keyword.debug',     { link = 'Debug' })
hi('@tag',               { link = 'Tag' })
hi('@tag.builtin',       { link = 'Special' })

-- LSP semantic tokens
hi('@lsp.type.class',         { link = 'Structure' })
hi('@lsp.type.comment',       { link = 'Comment' })
hi('@lsp.type.decorator',     { link = 'Function' })
hi('@lsp.type.enum',          { link = 'Structure' })
hi('@lsp.type.enumMember',    { link = 'Constant' })
hi('@lsp.type.function',      { link = 'Function' })
hi('@lsp.type.interface',     { link = 'Structure' })
hi('@lsp.type.macro',         { link = 'Macro' })
hi('@lsp.type.method',        { link = 'Function' })
hi('@lsp.type.namespace',     { link = 'Structure' })
hi('@lsp.type.parameter',     { link = 'Identifier' })
hi('@lsp.type.property',      { link = 'Identifier' })
hi('@lsp.type.struct',        { link = 'Structure' })
hi('@lsp.type.type',          { link = 'Type' })
hi('@lsp.type.typeParameter', { link = 'TypeDef' })
hi('@lsp.type.variable',      { link = 'Identifier' })

if vim.o.background == 'light' then
  -- Default colors only used with a light background.
  hi('ColorColumn',  { bg = 'LightRed',                            ctermbg = 'LightRed' })
  hi('CursorColumn', { bg = 'Grey90',                              ctermbg = 'LightGrey' })
  hi('CursorLine',   { bg = 'Grey90',                              cterm = { underline = true } })
  hi('CursorLineNr', { fg = 'Brown', bold = true,                  ctermfg = 'Brown', cterm = { underline = true } })
  hi('DiffAdd',      { bg = 'LightBlue',                           ctermbg = 'LightBlue' })
  hi('DiffChange',   { bg = 'LightMagenta',                        ctermbg = 'LightMagenta' })
  hi('DiffDelete',   { fg = 'Blue', bg = 'LightCyan', bold = true, ctermfg = 'Blue', ctermbg = 'LightCyan' })
  hi('Directory',    { fg = 'Blue',                                ctermfg = 'DarkBlue' })
  hi('FoldColumn',   { fg = 'DarkBlue', bg = 'Grey',               ctermfg = 'DarkBlue', ctermbg = 'Grey' })
  hi('Folded',       { fg = 'DarkBlue', bg = 'LightGrey',          ctermfg = 'DarkBlue', ctermbg = 'Grey' })
  hi('LineNr',       { fg = 'Brown',                               ctermfg = 'Brown' })
  hi('MatchParen',   { bg = 'Cyan',                                ctermbg = 'Cyan' })
  hi('MoreMsg',      { fg = 'SeaGreen', bold = true,               ctermfg = 'DarkGreen' })
  hi('Pmenu',        { bg = 'LightMagenta',                        ctermfg = 'Black', ctermbg = 'LightMagenta' })
  hi('PmenuSel',     { bg = 'Grey',                                ctermfg = 'Black', ctermbg = 'LightGrey' })
  hi('PmenuThumb',   { bg = 'Black',                               ctermbg = 'Black' })
  hi('Question',     { fg = 'SeaGreen', bold = true,               ctermfg = 'DarkGreen' })
  hi('Search',       { bg = 'Yellow',                              ctermbg = 'Yellow' })
  hi('SignColumn',   { fg = 'DarkBlue', bg = 'Grey',               ctermfg = 'DarkBlue', ctermbg = 'Grey' })
  hi('SpecialKey',   { fg = 'Blue',                                ctermfg = 'DarkBlue' })
  hi('SpellBad',     { sp = 'Red', undercurl = true,               ctermbg = 'LightRed' })
  hi('SpellCap',     { sp = 'Blue', undercurl = true,              ctermbg = 'LightBlue' })
  hi('SpellLocal',   { sp = 'DarkCyan', undercurl = true,          ctermbg = 'Cyan' })
  hi('SpellRare',    { sp = 'Magenta', undercurl = true,           ctermbg = 'LightMagenta' })
  hi('TabLine',      { bg = 'LightGrey', underline = true,         ctermfg = 'Black', ctermbg = 'LightGrey', cterm = { underline = true } })
  hi('Title',        { fg = 'Magenta', bold = true,                ctermfg = 'DarkMagenta' })
  hi('Visual',       { fg = 'Black', bg = 'LightGrey',             ctermfg = 'Black', ctermbg = 'Grey' })
  hi('WarningMsg',   { fg = 'Red',                                 ctermfg = 'DarkRed' })
  hi('Comment',      { fg = 'Blue',                                ctermfg = 'DarkBlue' })
  hi('Constant',     { fg = 'Magenta',                             ctermfg = 'DarkRed' })
  hi('Special',      { fg = '#6a5acd',                             ctermfg = 'DarkMagenta' })
  hi('Identifier',   { fg = 'DarkCyan',                            ctermfg = 'DarkCyan' })
  hi('Statement',    { fg = 'Brown', bold = true,                  ctermfg = 'Brown' })
  hi('PreProc',      { fg = '#6a0dad',                             ctermfg = 'DarkMagenta' })
  hi('Type',         { fg = 'SeaGreen', bold = true,               ctermfg = 'DarkGreen' })
  hi('Underlined',   { fg = 'SlateBlue', underline = true,         ctermfg = 'DarkMagenta', cterm = { underline = true } })
  hi('Ignore',       {                                             ctermfg = 'White' })
else
  -- Default colors only used with a dark background.
  hi('ColorColumn',  { bg = 'DarkRed',                            ctermbg = 'DarkRed' })
  hi('CursorColumn', { bg = 'Grey40',                             ctermbg = 'DarkGrey' })
  hi('CursorLine',   { bg = 'Grey40',                             cterm = { underline = true } })
  hi('CursorLineNr', { fg = 'Yellow', bold = true,                ctermfg = 'Yellow', cterm = { underline = true } })
  hi('DiffAdd',      { bg = 'DarkBlue',                           ctermbg = 'DarkBlue' })
  hi('DiffChange',   { bg = 'DarkMagenta',                        ctermbg = 'DarkMagenta' })
  hi('DiffDelete',   { fg = 'Blue', bg = 'DarkCyan', bold = true, ctermfg = 'Blue', ctermbg = 'DarkCyan' })
  hi('Directory',    { fg = 'Cyan',                               ctermfg = 'LightCyan' })
  hi('FoldColumn',   { fg = 'Cyan', bg = 'Grey',                  ctermfg = 'Cyan', ctermbg = 'DarkGrey' })
  hi('Folded',       { fg = 'Cyan', bg = 'DarkGrey',              ctermfg = 'Cyan', ctermbg = 'DarkGrey' })
  hi('LineNr',       { fg = 'Yellow',                             ctermfg = 'Yellow' })
  hi('MatchParen',   { bg = 'DarkCyan',                           ctermbg = 'DarkCyan' })
  hi('MoreMsg',      { fg = 'SeaGreen', bold = true,              ctermfg = 'LightGreen' })
  hi('Pmenu',        { bg = 'Magenta',                            ctermfg = 'Black', ctermbg = 'Magenta' })
  hi('PmenuSel',     { bg = 'DarkGrey',                           ctermfg = 'DarkGrey', ctermbg = 'Black' })
  hi('PmenuThumb',   { bg = 'White',                              ctermbg = 'White' })
  hi('Question',     { fg = 'Green', bold = true,                 ctermfg = 'LightGreen' })
  hi('Search',       { fg = 'Black', bg = 'Yellow',               ctermfg = 'Black', ctermbg = 'Yellow' })
  hi('SignColumn',   { fg = 'Cyan', bg = 'Grey',                  ctermfg = 'Cyan', ctermbg = 'DarkGrey' })
  hi('SpecialKey',   { fg = 'Cyan',                               ctermfg = 'LightBlue' })
  hi('SpellBad',     { sp = 'Red', undercurl = true,              ctermbg = 'Red' })
  hi('SpellCap',     { sp = 'Blue', undercurl = true,             ctermbg = 'Blue' })
  hi('SpellLocal',   { sp = 'Cyan', undercurl = true,             ctermbg = 'Cyan' })
  hi('SpellRare',    { sp = 'Magenta', undercurl = true,          ctermbg = 'Magenta' })
  hi('TabLine',      { bg = 'DarkGrey', underline = true,         ctermfg = 'White', ctermbg = 'DarkGrey', cterm = { underline = true } })
  hi('Title',        { fg = 'Magenta', bold = true,               ctermfg = 'LightMagenta' })
  hi('Visual',       { fg = 'LightGrey', bg = '#575757',          ctermfg = 'Black', ctermbg = 'Grey' })
  hi('WarningMsg',   { fg = 'Red',                                ctermfg = 'LightRed' })
  hi('Comment',      { fg = '#80a0ff',                            ctermfg = 'Cyan' })
  hi('Constant',     { fg = '#ffa0a0',                            ctermfg = 'Magenta' })
  hi('Special',      { fg = 'Orange',                             ctermfg = 'LightRed' })
  hi('Identifier',   { fg = '#40ffff',                            ctermfg = 'Cyan', cterm = { bold = true } })
  hi('Statement',    { fg = '#ffff60', bold = true,               ctermfg = 'Yellow' })
  hi('PreProc',      { fg = '#ff80ff',                            ctermfg = 'LightBlue' })
  hi('Type',         { fg = '#60ff60', bold = true,               ctermfg = 'LightGreen' })
  hi('Underlined',   { fg = '#80a0ff', underline = true,          ctermfg = 'LightBlue', cterm = { underline = true } })
  hi('Ignore',       {                                            ctermfg = 'Black' })
end
--stylua: ignore end

I have this line in my init.vim file:

source $XDG_CONFIG_HOME/nvim/colors.lua

Offline

#30 2024-10-21 13:24:13

seth
Member
Registered: 2012-09-03
Posts: 59,024

Re: Why nvim processes colors differently?

You've not elborated on the alpha patch situation and if that's the colorscheme used in both xterm shots, it's equivalent there as well.

Offline

#31 2024-10-21 16:03:29

b42
Member
Registered: 2023-07-20
Posts: 189

Re: Why nvim processes colors differently?

seth wrote:

You've not elborated on the alpha patch situation and if that's the colorscheme used in both xterm shots, it's equivalent there as well.

Yes, that is the colorscheme used in both of those xterm screenshots.

How exactly do I remove the alpha patch from my st build?

Offline

#32 2024-10-21 18:47:24

seth
Member
Registered: 2012-09-03
Posts: 59,024

Re: Why nvim processes colors differently?

How exactly do I remove the alpha patch from my st build?

By not adding it?
How exactly do you install st? Or archlinux, for that matter.

Offline

#33 2024-10-22 13:57:32

b42
Member
Registered: 2023-07-20
Posts: 189

Re: Why nvim processes colors differently?

seth wrote:

How exactly do I remove the alpha patch from my st build?

By not adding it?
How exactly do you install st? Or archlinux, for that matter.


I already have a build of st with a lot of customization and patches. not sure how do I remove a specific patch.

Offline

#34 2024-10-22 14:09:23

seth
Member
Registered: 2012-09-03
Posts: 59,024

Re: Why nvim processes colors differently?

What do you mean "you have a build"?
You're building st, while building it you're applying patches. Don't apply the argb patch.
You cannot "unpatch" the binary.


seth wrote:

How exactly do you install … archlinux?

Offline

#35 2024-10-22 14:38:49

b42
Member
Registered: 2023-07-20
Posts: 189

Re: Why nvim processes colors differently?

Does it mean I have to remove it manually in the source code files?

Offline

#36 2024-10-22 14:49:27

seth
Member
Registered: 2012-09-03
Posts: 59,024

Re: Why nvim processes colors differently?

The alpha patch does not have to be removed, you ecplicitly add it.

How do you install st?
How do you install archlinux?

Unless you're providing a meaningful and honest answer to those questions, you're on your own.
Right now, you do not make the impression as if you've the slightest idea what you're doing at all.

Offline

#37 2024-10-22 15:30:33

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,330
Website

Re: Why nvim processes colors differently?

b42, you've been warned multiple times before for being a help vampire (including at least one "final warning").  Yet you persist.  To be clear, lack of knowledge and experience is not the issue - but your lack of properly / actively participating in the troubleshooting process is: expecting to be spoon fed at every single stage is not acceptable in this community.

I've watched this thread and considered chiming in more - but quite honestly I've long since concluded that you are simply not worth the time / effort of even engaging with anymore.  But I considered chiming in on seth's behalf as he has far more patience than many of us - yet you've been wearing him down for a dozen posts or so in this thread. 

I can't say necessarily that any specific mod / admin actions would be taken - but I am quite confident that if after all this you push seth to the point of giving up on you, no one else will bother giving you the time of day.

Stop being a help vampire - engage your own brain in the troubleshooting process (and answer questions that are presented to you!  If you don't understand a question, ask for clarification, but do not ignore it).

Last edited by Trilby (2024-10-22 15:41:25)


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#38 2024-10-22 17:31:51

b42
Member
Registered: 2023-07-20
Posts: 189

Re: Why nvim processes colors differently?

seth wrote:

How do you install st?

I have the build and and I do

 sudo make install 
seth wrote:

How do you install archlinux?

What do you exactly mean by that? I install it manually, I get the install ISO and start with partitioning my drive.

I am not a complete newbie I understand some things but I am far from being an advanced user.

I have a question - you thought that the issue here is either colorscheme or st.

I have always thought that colors described in st build are specifically for st and how it reflects in the terminal.

vim is a terminal application, I am of course aware of that, but I used to think that nvim colorscheme overrides st colors? Am I wrong here then?


Trilby, I am trying to participate and give as much information as I can, as for those latter questions regarding how do I install I took it as a sarcasm, since I have experienced here a bit.

Last edited by b42 (2024-10-22 17:37:29)

Offline

#39 2024-10-22 18:00:21

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,330
Website

Re: Why nvim processes colors differently?

b42 wrote:

I used to think that nvim colorscheme overrides st colors? Am I wrong here then?

That is wrong.  Any terminal application can specify colors - in many cases, including this one, the application specifies colors as one of 256 color codes.  The terminal emulator then determines what each of those 256 colors actually are.  There are defacto standards that, for example, color 1 is red / redish, 2 green / greenish, etc, but there each terminal may use different shades of these colors (or really they can make them completely different colors too if configured so).

The default st config.h defines the first 16 colors explicitly, and if nothing else is added, it uses a color-cube template for colors 17-255 (inherited from xterm most likely).  But any of this can be changed at compile time.  So there are many moving parts here all of which can affect the color that shows up on your screen.  Early in this thread we asked for and eventually got screenshots of the 256 color display - this was (intended) to confirm that st is using the same colors on both systems.  But frankly, at this point I'm not sure whether those screenshots were even showing what was asked for (given the whole oddity about some screenshots showing transparency and others not, etc ... nothing added up, at all).

Throughout this thread you may have changed or reported on one variable at a time, but meanwhile many other variables were also changing (hence my comment of comparing apples to oranges).  Troubleshooting problems must proceed via a logical systematic process (or I suppose an alternative would be trying random suggestions and hoping by dumb luck they might work - but we don't do that here): yet at every stage of this process multiple variables change at once making a logical or systematic approach impossible. 

No one here has any idea what's going on in your system at this point - and this leads to the not-unreasonable suspicion that you also have no idea what's going on in your system (hence the implied suspicion that you are not running arch linux and / or you did not install it following official means - it's not sarcasm, it is a highly plausible hypothesis derived from the available evidence).  I'm not even going to ask why you building st manually rather than making a package via the AUR.

Last edited by Trilby (2024-10-22 18:01:09)


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#40 2024-10-22 18:25:45

seth
Member
Registered: 2012-09-03
Posts: 59,024

Re: Why nvim processes colors differently?

I have the build and and I do

And how "have you built"? The building part is where the patches get applied to the bare st code, don't apply the argb patch, you'll not get any alpha channel.

What we do know (more or less) is that the concerned vim colorscheme is the same on xterm, but different on st on across systems.
We also know that a different scheme (desert) is the same on st across systems.
You've suggested that the alpha channel only works with the concerned color scheme, but not others (incl. desert)

So if we infer that the argb patch is a ciritical element, we want to try w/o.

What do you exactly mean by that? I install it manually, I get the install ISO and start with partitioning my drive.

I meant what scripts or tutorials you used.
Here's the thing: you're asserting to use the alpha patch w/ st.
This requires you to explicitly patch st and build it.
But you're also claiming that you don't know how to build st w/o the alpha patch.
This. Does. Not. Add. Up.

Offline

#41 2024-10-23 09:52:37

sainishwanth
Member
Registered: 2022-11-19
Posts: 17

Re: Why nvim processes colors differently?

Just chiming in to give some advice, not sure if it will help, but could you try to build a pre-patched version of st and see if the colors are still being affected? Maybe something like the Luke Smith build - https://github.com/LukeSmithxyz/st

Try building this (it's the exact same process as building your normal st) and see if the colors are still altered, then you can maybe get an idea that something with your system is wrong, or something with your st build was wrong.

Offline

#42 2024-10-23 10:47:36

b42
Member
Registered: 2023-07-20
Posts: 189

Re: Why nvim processes colors differently?

sainishwanth wrote:

Just chiming in to give some advice, not sure if it will help, but could you try to build a pre-patched version of st and see if the colors are still being affected? Maybe something like the Luke Smith build - https://github.com/LukeSmithxyz/st

Try building this (it's the exact same process as building your normal st) and see if the colors are still altered, then you can maybe get an idea that something with your system is wrong, or something with your st build was wrong.

I use Luke Smith's build. smile

Offline

#43 2024-10-23 12:03:02

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,330
Website

Re: Why nvim processes colors differently?

*headdesk*  There's that other shoe we were all waiting to drop.  And why after all this time of being asked repeatedly about how you build st, only now this comes up: you clearly were deliberately hiding this very relevant fact.

Mr Smiths "contributions" are well on their way to being the next OMZ.  If you want support for Luke Smith's "creative" approaches, you'll have to ask him.  They have a history of 1) breaking things in really weird and unpredictable ways, and 2) resulting in users that are completely fucking clueless.  It's two for two on this one.

Stop acting like you're allergic to knowledge, that will not serve you well.  It seems your entire history of problems documented in your many threads on this forum are all the result of trying to take what someone presented to you as the "easy way" rather than spending five minutes engaging your own brain cells or even bothering to look at the countless resources this community has made available to help new users.

Note that your st build uses dynamic colors: they're expected to change from time to time.  That's one of the built in "features".

TLDR: play stupid games, win stupid prizes.

Last edited by Trilby (2024-10-23 12:07:07)


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#44 2024-10-23 12:11:11

seth
Member
Registered: 2012-09-03
Posts: 59,024

Re: Why nvim processes colors differently?

lol
I was gonna object to sainishwanth because adding more variables to the problem would not be helpful, but then figured to better hold back as this prompt might result in exactly #42 to explain everything in this thread.

@b42, the reason why things behave differently is because they're different and the problem is that you don't even know that.
https://github.com/LukeSmithxyz/st?tab= … etty-stuff

Compatibility with Xresources and pywal for dynamic colors.
Default gruvbox colors otherwise.

I don't mind you using someones forks of st, but that does not excuse you from not being aware of the fork and certainly not from not revealing it.
My money is on pywal.

Edit: F5ck'd by a parrot…

Last edited by seth (2024-10-23 12:11:44)

Offline

#45 2024-10-23 20:27:44

b42
Member
Registered: 2023-07-20
Posts: 189

Re: Why nvim processes colors differently?

Lol, I definitely did not hide this fact deliberately. It would be a complete waste of my time.

I have done countless reinstalls of my system in order for the process to stick to my mind and I have learnt a bit every single time. And at least 10 times until now those colors stayed the same, since I always use the same config files, same st, dwm builds etc. That is why I was surprised why they got different this time if I did not change any single thing.

Now, sorry if that caused so much trouble, honestly, this was not my intention.

Do I get it right that I have to get rid of pywal? Which I have no clue of what it is smile

Last edited by b42 (2024-10-23 20:29:09)

Offline

#46 2024-10-23 20:44:18

seth
Member
Registered: 2012-09-03
Posts: 59,024

Re: Why nvim processes colors differently?

I'd start by building a vanilla st and see whether your problems are gone w/ that.
Then search the wiki for pywal.
Then ask LS about the patch - the repo doesn't say what that actually is:  https://github.com/LukeSmithxyz/st/issu … ssue+pywal

Offline

#47 2024-10-25 15:40:07

b42
Member
Registered: 2023-07-20
Posts: 189

Re: Why nvim processes colors differently?

Okay I just installed vanilla st.

Got it from here:

https://dl.suckless.org/st/st-0.9.2.tar.gz


Still get the same colorscheme as I would get from Luke Smith's st build.

Can we safely assume the problem is not in st then?

Offline

#48 2024-10-25 15:41:46

seth
Member
Registered: 2012-09-03
Posts: 59,024

Re: Why nvim processes colors differently?

Of course you're getting the same colorscheme - the question is whether it looks the same on both systems when using the vanilla st on both systems…

Offline

#49 2024-10-25 15:54:34

b42
Member
Registered: 2023-07-20
Posts: 189

Re: Why nvim processes colors differently?

okay, now I just uninstalled Luke Smith's st on my old system (the desired colorscheme) and reinstalled the same st build again.

And I get that different colorscheme, the same as in my new system.

What does it tell us?

Offline

#50 2024-11-02 12:18:21

b42
Member
Registered: 2023-07-20
Posts: 189

Re: Why nvim processes colors differently?

Any ideas on this matter? I know it's double posting, if no one has any insight I will be refused to mark it as solved, because it is not in my power to solve this myself.

Offline

Board footer

Powered by FluxBB