diff options
| author | Daniel Eklöf <daniel@ekloef.se> | 2020-08-16 14:58:32 +0000 |
|---|---|---|
| committer | Daniel Eklöf <daniel@ekloef.se> | 2020-08-16 14:58:32 +0000 |
| commit | d4473c4e67bd10dfb7ee4816d34c50bfb33d0138 (patch) | |
| tree | 8062094c9ecda7ee0b0b141f26db5fa75e1d3241 | |
| parent | csi: xtsave: store modes' SET state, not the current state (diff) | |
term: xtsave: store state in a bitfield
These shouldn't be accessed in any performance critical paths, so lets
save some memory and use a bitfield.
| -rw-r--r-- | terminal.h | 40 |
1 files changed, 20 insertions, 20 deletions
@@ -248,26 +248,26 @@ struct terminal { /* Saved DECSET modes - we save the SET state */ struct { - bool origin; - bool application_cursor_keys; - bool reverse; - bool show_cursor; - bool auto_margin; - //bool cursor_blink; - bool insert_mode; - bool bracketed_paste; - bool focus_events; - bool alt_scrolling; - //bool mouse_x10; - bool mouse_click; - bool mouse_drag; - bool mouse_motion; - //bool mouse_utf8; - bool mouse_sgr; - bool mouse_urxvt; - bool meta_eight_bit; - bool meta_esc_prefix; - bool alt_screen; + uint32_t origin:1; + uint32_t application_cursor_keys:1; + uint32_t reverse:1; + uint32_t show_cursor:1; + uint32_t auto_margin:1; + //uint32_t cursor_blink:1; + uint32_t insert_mode:1; + uint32_t bracketed_paste:1; + uint32_t focus_events:1; + uint32_t alt_scrolling:1; + //uint32_t mouse_x10:1; + uint32_t mouse_click:1; + uint32_t mouse_drag:1; + uint32_t mouse_motion:1; + //uint32_t mouse_utf8:1; + uint32_t mouse_sgr:1; + uint32_t mouse_urxvt:1; + uint32_t meta_eight_bit:1; + uint32_t meta_esc_prefix:1; + uint32_t alt_screen:1; } xtsave; struct charsets charsets; |
