STRUCT VC_STATE(9)
π struct vc_state(9) β the Kernel API Manual era
okay bestie, so we're in the Kernel API Manual today and the topic is struct vc_state(9) β which is literally just the state of a VC. that's it, that's the vibe.
β¨ NAME β¨
struct vc_state β state of a VC. short, sweet, iconic, no notes π
πΈ SYNOPSIS πΈ
struct vc_state {
unsigned int x, y;
unsigned char color;
unsigned char Gx_charset[2];
unsigned int charset : 1;
enum vc_intensity intensity;
bool italic;
bool underline;
bool blink;
bool reverse;
};
look at her. main character struct. copy her exactly, no cap π«Ά
π Members π
here's the roster, and honestly everyone ate:
xβ cursor's x-position πyβ cursor's y-position π (yes, the partner-in-crime coordinate, we love a duo)colorβ foreground & background colors π¨Gx_charsetβ what's G0/G1 slot set to (likeGRAF_MAP,LAT1_MAP) π€charsetβ what character set to use (0=G0 or1=G1) π§intensityβ seeenum vc_intensityfor values βreverseβ reversed foreground/background colors π
ngl, the struct itself also carriesitalic,underline, andblinkβ they're right there in the synopsis, slaying in plain sight. the member writeups here just don't cover them, so don't come for me, I'm only repeating what the page says π
π¦ Description π¦
so why does this exist as its own whole struct instead of being glued into struct vc_data? because these members are defined separately from struct vc_data β we save & restore them at times. that's the whole reason. we stan a modular queen π
π₯ SEE ALSO π₯
- Kernel file
./include/linux/console_struct.h struct vc_font(9)
lowkey a tiny page but every single detail is here, fr fr π
and that's the tea β shipped from ./include/linux, dated October 2026, brought to you by the struct vc_state(9) girlies β¨π go read struct vc_font(9) next, iykyk π¦
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms