Skip to content
This repository has been archived by the owner on Oct 2, 2023. It is now read-only.

Escape codes theme(s) #4

Closed
5 tasks done
Raffaello opened this issue Apr 3, 2022 · 4 comments · Fixed by #37 or #38
Closed
5 tasks done

Escape codes theme(s) #4

Raffaello opened this issue Apr 3, 2022 · 4 comments · Fixed by #37 or #38
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@Raffaello
Copy link
Collaborator

Raffaello commented Apr 3, 2022

Themes

  • replace writing colors with ESC[ escape codes
  • 16 colors
  • 256 colors
  • 24 bits colors
  • underline, bold, italic, inverse etc... text colors

Improvements with escape sequence to support more colors, eg:

PS C:\> "`e[38;5;100mSample\`e[0m"

Note:

ESC[ char is e`

256-colors

ESC[38;5;⟨n⟩m Select foreground color
ESC[48;5;⟨n⟩m Select background color
  0-  7:  standard colors (as in ESC [ 30–37 m)
  8- 15:  high intensity colors (as in ESC [ 90–97 m)
 16-231:  6 × 6 × 6 cube (216 colors): 16 + 36 × r + 6 × g + b (0 ≤ r, g, b ≤ 5)
232-255:  grayscale from black to white in 24 steps

24-bits:

ESC[38;2;⟨r⟩;⟨g⟩;⟨b⟩mSelect RGB foreground color
ESC[ 48;2;⟨r⟩;⟨g⟩;⟨b⟩ m Select RGB background color

the sequence must end with:

ESC[0m

eg 24-bits

"`e[38;2;255;128;64mRGB Text`e[0m"

more info on VT100 ansi terminal:

it is possible to underline text, bold, etc and so on too.

@Raffaello
Copy link
Collaborator Author

@Raffaello Raffaello linked a pull request Apr 6, 2022 that will close this issue
@Raffaello Raffaello self-assigned this Apr 14, 2022
@Raffaello Raffaello added the enhancement New feature or request label Apr 14, 2022
@Raffaello Raffaello added this to the v0.0.3 milestone Apr 15, 2022
@Raffaello Raffaello removed a link to a pull request Apr 15, 2022
@Raffaello Raffaello changed the title personalized themes Escape codes theme(s) Apr 15, 2022
@Raffaello
Copy link
Collaborator Author

@Raffaello
Copy link
Collaborator Author

Raffaello commented Apr 18, 2022

extend getpowerdirinfo with types.ps1xml schema.
ref: https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_types.ps1xml?view=powershell-7.2

to have a string of that requires to create format.ps1xml files as custom view.

so need to remove the string output, but instead outputting everything as an object.

(ok to start with string first)

@Raffaello
Copy link
Collaborator Author

This was linked to pull requests Apr 23, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant