contour-terminal / contour

Modern C++ Terminal Emulator
http://contour-terminal.org/
Apache License 2.0
2.32k stars 102 forks source link

CSI 1 m fails to brighten default-foreground text #1383

Closed 0x5c closed 6 months ago

0x5c commented 6 months ago

Contour Terminal version

Contour Terminal Emulator 0.4.0

Installer source

something else (please specify below)

Operating System

VoidLinux

Architecture

x86-64

Other Software

No response

Steps to reproduce

  1. Set draw_bold_text_with_bright_colors: true
  2. Reset any styling (CSI 0 m)
  3. echo "\033[1m█"

Expected Behavior

The block is displayed brighter than the default colour

Actual Behavior

The colour of the block is the same as the default colour

Additional notes

image

christianparpart commented 6 months ago

Hey, would you mind giving that a try?

#! /bin/bash

NORMAL="NORMAL █"
BOLD_OR_BRIGHT="█ BOLD/BRIGHT"

for i in {0..7} ; do
    printf "${i}: \e[0m\e[3${i}m${NORMAL}\e[1m${BOLD_OR_BRIGHT}\e[0m\n"
done

For me, this looks like the following:

image

Mind, this may look different, depending on color profile. Maybe you can share your color settings also?

Many thanks, and Merry Christmas :)

0x5c commented 6 months ago

Sure thing image

Colour scheme ```yaml default: # Default background color (this can be made transparent, see above). background: '#060606' # Default foreground text color. foreground: '#d0d0d0' # Background image support. background_image: # Full path to the image to use as background. # # Default: empty string (disabled) # path: '/Users/trapni/Pictures/bg.png' # Image opacity to be applied to make the image not look to intense # and not get too distracted by the background image. # Default: 0.5 opacity: 0.5 # Optionally blurs background image to make it less distracting # and keep the focus on the actual terminal contents. # # Default: false blur: false # Mandates the color of the cursor and potentially overridden text. # # The color can be specified in RGB as usual, plus # - CellForeground: Selects the cell's foreground color. # - CellBackground: Selects the cell's background color. cursor: # Specifies the color to be used for the actual cursor shape. # # Default: CellForeground default: CellForeground # Specifies the color to be used for the characters that would # be covered otherwise. # # Default: CellBackground text: CellBackground # color to pick for hyperlinks decoration, when hovering hyperlink_decoration: normal: '#f0f000' hover: '#ff0000' # Color to pick for vi_mode highlights. # The value format is equivalent to how selection colors and alpha contribution is defined. vi_mode_highlight: foreground: CellForeground foreground_alpha: 1.0 background: '#ffa500' background_alpha: 0.5 # Color override for the current cursor's line when in vi_mode: # The value format is equivalent to how selection colors and alpha contribution is defined. # To disable cursorline in vi_mode, set foreground to CellForeground and background to CellBackground. vi_mode_cursorline: foreground: '#ffffff' foreground_alpha: 0.2 background: '#808080' background_alpha: 0.4 # The text selection color can be customized here. # Leaving a value empty will default to the inverse of the content's color values. # # The color can be specified in RGB as usual, plus # - CellForeground: Selects the cell's foreground color. # - CellBackground: Selects the cell's background color. selection: # Specifies the color to be used for the selected text. # # Default: CellBackground foreground: CellBackround # Specifies the alpha value (between 0.0 and 1.0) the configured foreground color # will contribute to the original color. # # A value of 1.0 will paint over, whereas a value of 0.5 will give # a look of a half-transparently painted grid cell. foreground_alpha: 1.0 # Specifies the color to be used for the selected background. # # Default: CellForeground #background: '#4040f0' background: CellForeground # Specifies the alpha value (between 0.0 and 1.0) the configured background color # will contribute to the original color. # # A value of 1.0 will paint over, whereas a value of 0.5 will give # a look of a half-transparently painted grid cell. background_alpha: 0.5 # Search match highlighting. Similar to selection highlighting. search_highlight: foreground: CellBackground background: CellForeground foreground_alpha: 1.0 background_alpha: 1.0 # Search match highlighting (focused term). Similar to selection highlighting. search_highlight_focused: foreground: CellBackground background: CellForeground foreground_alpha: 1.0 background_alpha: 1.0 # Coloring for the word that is highlighted due to double-clicking it. # # The format is similar to selection highlighting. word_highlight_current: foreground: CellForeground background: '#909090' foreground_alpha: 1.0 background_alpha: 0.5 # Coloring for the word that is highlighted due to double-clicking # another word that matches this word. # # The format is similar to selection highlighting. word_highlight_other: foreground: CellForeground background: '#909090' foreground_alpha: 1.0 background_alpha: 0.5 # Defines the colors to be used for the Indicator status line. # Values must be in RGB form. indicator_statusline: # Default: default background foreground: '#808080' # Default: default foreground background: '#1c1c1c' # Alternate colors to be used for the indicator status line when # this terminal is currently not in focus. indicator_statusline_inactive: # Default: default background foreground: '#808080' # Default: default foreground background: '#000000' # Colors for the IME (Input Method Editor) area. input_method_editor: # Default: default #FFFFFF foreground: '#FFFFFF' # Default: default #FF0000 background: '#FF0000' # Normal colors normal: black: '#000000' red: '#cd0000' green: '#00cd00' yellow: '#cdcd00' blue: '#1093f5' magenta: '#cd00cd' cyan: '#00a0a0' white: '#d0d0d0' # Bright colors bright: black: '#404040' red: '#ff0000' green: '#00ff00' yellow: '#ffff00' blue: '#11b5f6' magenta: '#ff00ff' cyan: '#00ffff' white: '#ffffff' # Dim (faint) colors, if not set, they're automatically computed based on normal colors. # dim: # black: '#1d1f21' # red: '#cc342b' # green: '#198844' # yellow: '#fba922' # blue: '#3971ed' # magenta: '#a36ac7' # cyan: '#3971ed' # white: '#c5c8c6' ```

Most notably I think, both the default foreground and "normal white" have the same value

christianparpart commented 6 months ago

Okay sorry, my brain is still delivering christmas presents and therefore being offline. Now I understand. So this is actually not a bug but rather a missing feature. I'll be creating a PR to it as soon as possible. :)