instalation script was made easyer so that just config.sh should be modified

master
Kerem Yollu 2 years ago
parent 1d238895a9
commit 35141524f0

@ -0,0 +1,40 @@
#!/bin/bash
MAIN_DIR=$PWD
source $MAIN_DIR/programs/os/debian_install.sh
source $MAIN_DIR/programs/os/arch_install.sh
source $MAIN_DIR/programs/os/raspberry_install.sh
sleepTime=0.3
os_list=(debian arch raspberry)
pckgmngr_list=('sudo apt -y install' 'yes | sudo pacman -S' 'sudo apt -y install')
common_programs_list=(\
htop \
tmux \
git \
fish \
mc \
wget \
sudo \
unzip \
cmake \
make \
gcc \
exa)
default_installs_debian=(qutebrowser)
default_installs_arch=(qutebrowser)
default_installs_raspberry=(chromium)
custom_installs_debian=(dmenu fonts)
custom_installs_arch=(dmenu fonts)
custom_installs_raspberry=(dmenu fonts)
os_count=${#os_list[@]}
pckgmngr_count=${#pckgmngr_list[@]}
OS="Wil be initialized in setup.sh"

@ -0,0 +1,870 @@
# Configuration for Alacritty, the GPU enhanced terminal emulator.
# Any items in the `env` entry below will be added as
# environment variables. Some entries may override variables
# set by alacritty itself.
env:
# TERM variable
#
# This value is used to set the `$TERM` environment variable for
# each instance of Alacritty. If it is not present, alacritty will
# check the local terminfo database and use `alacritty` if it is
# available, otherwise `xterm-256color` is used.
TERM: xterm-256color
window:
# Window dimensions (changes require restart)
#
# Specified in number of columns/lines, not pixels.
# If both are `0`, this setting is ignored.
#dimensions:
# columns: 0
# lines: 0
# Window position (changes require restart)
#
# Specified in number of pixels.
# If the position is not set, the window manager will handle the placement.
#position:
# x: 0
# y: 0
# Window padding (changes require restart)
#
# Blank space added around the window in pixels. This padding is scaled
# by DPI and the specified value is always added at both opposing sides.
padding:
x: 6
y: 6
# Spread additional padding evenly around the terminal content.
dynamic_padding: false
# Background opacity
#
# Window opacity as a floating point number from `0.0` to `1.0`.
# The value `0.0` is completely transparent and `1.0` is opaque.
opacity: 0.8
# opacity: 0.80
# Window decorations
#
# Values for `decorations`:
# - full: Borders and title bar
# - none: Neither borders nor title bar
#
# Values for `decorations` (macOS only):
# - transparent: Title bar, transparent background and title bar buttons
# - buttonless: Title bar, transparent background, but no title bar buttons
#decorations: full
# Startup Mode (changes require restart)
#
# Values for `startup_mode`:
# - Windowed
# - Maximized
# - Fullscreen
#
# Values for `startup_mode` (macOS only):
# - SimpleFullscreen
#startup_mode: Windowed
# Window title
title: Alacritty
# Window class (Linux/BSD only):
class:
# Application instance name
instance: Alacritty
# General application class
general: Alacritty
# GTK theme variant (Linux/BSD only)
#
# Override the variant of the GTK theme. Commonly supported values are `dark` and `light`.
# Set this to `None` to use the default theme variant.
#gtk_theme_variant: None
scrolling:
# Maximum number of lines in the scrollback buffer.
# Specifying '0' will disable scrolling.
history: 5000
# Number of lines the viewport will move for every line scrolled when
# scrollback is enabled (history > 0).
#multiplier: 3
# Scroll to the bottom when new text is written to the terminal.
#auto_scroll: false
# Spaces per Tab (changes require restart)
#
# This setting defines the width of a tab in cells.
#
# Some applications, like Emacs, rely on knowing about the width of a tab.
# To prevent unexpected behavior in these applications, it's also required to
# change the `it` value in terminfo when altering this setting.
#tabspaces: 8
# Font configuration
font:
# Normal (roman) font face
normal:
# Font family
#
# Default:
# - (macOS) Menlo
# - (Linux/BSD) monospace
# - (Windows) Consolas
family: Source Code Pro
# family: CodeNewRoman Nerd Font
# family: RobotoMono Nerd Font
# family: Hack
# family: JetBrains Mono
# family: UbuntuMono Nerd Font
# family: Monofur Nerd Font
# family: TerminessTTF Nerd Font
# family: Mononoki Nerd Font
# The `style` can be specified to pick a specific face.
style: Regular
# Bold font face
bold:
# Font family
#
# If the bold family is not specified, it will fall back to the
# value specified for the normal font.
family: Source Code Pro
# family: CodeNewRoman Nerd Font
# family: RobotoMono Nerd Font
# family: Hack
# family: JetBrains Mono
# family: UbuntuMono Nerd Font
# family: Monofur Nerd Font
# family: TerminessTTF Nerd Font
# family: Mononoki Nerd Font
# The `style` can be specified to pick a specific face.
style: Bold
# Italic font face
italic:
# Font family
#
# If the italic family is not specified, it will fall back to the
# value specified for the normal font.
family: Source Code Pro
# family: CodeNewRoman Nerd Font
# family: RobotoMono Nerd Font
# family: Hack
# family: JetBrains Mono
# family: UbuntuMono Nerd Font
# family: Monofuritalic Nerd Font Mono
# family: TerminessTTF Nerd Font
# family: Mononoki Nerd Font
# The `style` can be specified to pick a specific face.
style: Italic
# Bold italic font face
bold_italic:
# Font family
#
# If the bold italic family is not specified, it will fall back to the
# value specified for the normal font.
family: Source Code Pro
# family: CodeNewRoman Nerd Font
# family: RobotoMono Nerd Font
# family: Hack
# family: JetBrains Mono
# family: UbuntuMono Nerd Font
# family: Monofuritalic Nerd Font Mono
# family: TerminessTTF Nerd Font
# family: Mononoki Nerd Font
# The `style` can be specified to pick a specific face.
style: Bold Italic
# Point size
size: 16
# Offset is the extra space around each character. `offset.y` can be thought of
# as modifying the line spacing, and `offset.x` as modifying the letter spacing.
offset:
x: 0
y: 1
# Glyph offset determines the locations of the glyphs within their cells with
# the default being at the bottom. Increasing `x` moves the glyph to the right,
# increasing `y` moves the glyph upwards.
#glyph_offset:
# x: 0
# y: 0
# Thin stroke font rendering (macOS only)
#
# Thin strokes are suitable for retina displays, but for non-retina screens
# it is recommended to set `use_thin_strokes` to `false`
#
# macOS >= 10.14.x:
#
# If the font quality on non-retina display looks bad then set
# `use_thin_strokes` to `true` and enable font smoothing by running the
# following command:
# `defaults write -g CGFontRenderingFontSmoothingDisabled -bool NO`
#
# This is a global setting and will require a log out or restart to take
# effect.
#use_thin_strokes: true
# If `true`, bold text is drawn using the bright color variants.
draw_bold_text_with_bright_colors: true
#######################################
## START OF COLOR SCHEMES ##
#######################################
schemes:
### Doom One ###
DoomOne: &DoomOne
primary:
background: '#282c34'
foreground: '#bbc2cf'
cursor:
text: CellBackground
cursor: '#528bff'
selection:
text: CellForeground
background: '#3e4451'
normal:
black: '#1c1f24'
red: '#ff6c6b'
green: '#98be65'
yellow: '#da8548'
blue: '#51afef'
magenta: '#c678dd'
cyan: '#5699af'
white: '#202328'
bright:
black: '#5b6268'
red: '#da8548'
green: '#4db5bd'
yellow: '#ecbe7b'
blue: '#3071db' # This is 2257a0 in Doom Emacs but I lightened it.
magenta: '#a9a1e1'
cyan: '#46d9ff'
white: '#dfdfdf'
### Dracula ###
Dracula: &Dracula
primary:
background: '#282a36'
foreground: '#f8f8f2'
cursor:
text: CellBackground
cursor: CellForeground
vi_mode_cursor:
text: CellBackground
cursor: CellForeground
search:
matches:
foreground: '#44475a'
background: '#50fa7b'
focused_match:
foreground: '#44475a'
background: '#ffb86c'
bar:
background: '#282a36'
foreground: '#f8f8f2'
line_indicator:
foreground: None
background: None
selection:
text: CellForeground
background: '#44475a'
normal:
black: '#000000'
red: '#ff5555'
green: '#50fa7b'
yellow: '#f1fa8c'
blue: '#bd93f9'
magenta: '#ff79c6'
cyan: '#8be9fd'
white: '#bfbfbf'
bright:
black: '#4d4d4d'
red: '#ff6e67'
green: '#5af78e'
yellow: '#f4f99d'
blue: '#caa9fa'
magenta: '#ff92d0'
cyan: '#9aedfe'
white: '#e6e6e6'
dim:
black: '#14151b'
red: '#ff2222'
green: '#1ef956'
yellow: '#ebf85b'
blue: '#4d5b86'
magenta: '#ff46b0'
cyan: '#59dffc'
white: '#e6e6d1'
### Gruvbox dark ###
GruvboxDark: &GruvboxDark
# Default colors
primary:
# hard contrast: background = '0x1d2021'
background: '#282828'
# soft contrast: background = '0x32302f'
foreground: '#ebdbb2'
# Normal colors
normal:
black: '#282828'
red: '#cc241d'
green: '#98971a'
yellow: '#d79921'
blue: '#458588'
magenta: '#b16286'
cyan: '#689d6a'
white: '#a89984'
# Bright colors
bright:
black: '#928374'
red: '#fb4934'
green: '#b8bb26'
yellow: '#fabd2f'
blue: '#83a598'
magenta: '#d3869b'
cyan: '#8ec07c'
white: '#ebdbb2'
### Monokai ###
MonokaiPro: &MonokaiPro
# Default colors
primary:
background: '#2D2A2E'
foreground: '#FCFCFA'
# Normal colors
normal:
black: '#403E41'
red: '#FF6188'
green: '#A9DC76'
yellow: '#FFD866'
blue: '#FC9867'
magenta: '#AB9DF2'
cyan: '#78DCE8'
white: '#FCFCFA'
# Bright colors
bright:
black: '#727072'
red: '#FF6188'
green: '#A9DC76'
yellow: '#FFD866'
blue: '#FC9867'
magenta: '#AB9DF2'
cyan: '#78DCE8'
white: '#FCFCFA'
### Nord ###
Nord: &Nord
# Default colors
primary:
background: '#2E3440'
foreground: '#D8DEE9'
# Normal colors
normal:
black: '#3B4252'
red: '#BF616A'
green: '#A3BE8C'
yellow: '#EBCB8B'
blue: '#81A1C1'
magenta: '#B48EAD'
cyan: '#88C0D0'
white: '#E5E9F0'
# Bright colors
bright:
black: '#4C566A'
red: '#BF616A'
green: '#A3BE8C'
yellow: '#EBCB8B'
blue: '#81A1C1'
magenta: '#B48EAD'
cyan: '#8FBCBB'
white: '#ECEFF4'
### Oceanic Next ###
OceanicNext: &OceanicNext
# Default colors
primary:
background: '#1b2b34'
foreground: '#d8dee9'
# Colors the cursor will use if `custom_cursor_colors` is true
cursor:
text: '#1b2b34'
cursor: '#ffffff'
# Normal colors
normal:
black: '#343d46'
red: '#EC5f67'
green: '#99C794'
yellow: '#FAC863'
blue: '#6699cc'
magenta: '#c594c5'
cyan: '#5fb3b3'
white: '#d8dee9'
# Bright colors
bright:
black: '#343d46'
red: '#EC5f67'
green: '#99C794'
yellow: '#FAC863'
blue: '#6699cc'
magenta: '#c594c5'
cyan: '#5fb3b3'
white: '#d8dee9'
### Palenight ###
Palenight: &Palenight
# Default colors
primary:
background: '#292d3e'
foreground: '#d0d0d0'
# Normal colors
normal:
black: '#292d3e'
red: '#f07178'
green: '#c3e88d'
yellow: '#ffcb6b'
blue: '#82aaff'
magenta: '#c792ea'
cyan: '#89ddff'
white: '#d0d0d0'
# Bright colors
bright:
black: '#434758'
red: '#ff8b92'
green: '#ddffa7'
yellow: '#ffe585'
blue: '#9cc4ff'
magenta: '#e1acff'
cyan: '#a3f7ff'
white: '#ffffff'
### Solarized Dark ###
SolarizedDark: &SolarizedDark
# Default colors
primary:
background: '#002b36' # base03
foreground: '#839496' # base0
# Cursor colors
cursor:
text: '#002b36' # base03
cursor: '#839496' # base0
# Normal colors
normal:
black: '#073642' # base02
red: '#dc322f' # red
green: '#859900' # green
yellow: '#b58900' # yellow
blue: '#268bd2' # blue
magenta: '#d33682' # magenta
cyan: '#2aa198' # cyan
white: '#eee8d5' # base2
# Bright colors
bright:
black: '#002b36' # base03
red: '#cb4b16' # orange
green: '#586e75' # base01
yellow: '#657b83' # base00
blue: '#839496' # base0
magenta: '#6c71c4' # violet
cyan: '#93a1a1' # base1
white: '#fdf6e3' # base3
### Solarized Light ###
SolarizedLight: &SolarizedLight
# Default colors
primary:
background: '#fdf6e3' # base3
foreground: '#657b83' # base00
# Cursor colors
cursor:
text: '#fdf6e3' # base3
cursor: '#657b83' # base00
# Normal colors
normal:
black: '#073642' # base02
red: '#dc322f' # red
green: '#859900' # green
yellow: '#b58900' # yellow
blue: '#268bd2' # blue
magenta: '#d33682' # magenta
cyan: '#2aa198' # cyan
white: '#eee8d5' # base2
# Bright colors
bright:
black: '#002b36' # base03
red: '#cb4b16' # orange
green: '#586e75' # base01
yellow: '#657b83' # base00
blue: '#839496' # base0
magenta: '#6c71c4' # violet
cyan: '#93a1a1' # base1
white: '#fdf6e3' # base3
### Tomorrow Night ###
TomorrowNight: &TomorrowNight
# Default colors
primary:
background: '#1d1f21'
foreground: '#c5c8c6'
# Colors the cursor will use if `custom_cursor_colors` is true
cursor:
text: '#1d1f21'
cursor: '#ffffff'
# Normal colors
normal:
black: '#1d1f21'
red: '#cc6666'
green: '#b5bd68'
yellow: '#e6c547'
blue: '#81a2be'
magenta: '#b294bb'
cyan: '#70c0ba'
white: '#373b41'
# Bright colors
bright:
black: '#666666'
red: '#ff3334'
green: '#9ec400'
yellow: '#f0c674'
blue: '#81a2be'
magenta: '#b77ee0'
cyan: '#54ced6'
white: '#282a2e'
######################################################################
## SET THEME: Choose ONE color scheme from those in the above list. ##
## ###################################################################
# Available themes are:
# *DoomOne
# *Dracula
# *GruvboxDark
# *MonokaiPro
# *Nord
# *OceanicNext
# *Palenight
# *SolarizedLight
# *SolarizedDark
# *TomorrowNight
colors: *DoomOne
#######################################
## END OF COLOR SCHEMES ##
#######################################
# Visual Bell
#
# Any time the BEL code is received, Alacritty "rings" the visual bell. Once
# rung, the terminal background will be set to white and transition back to the
# default background color. You can control the rate of this transition by
# setting the `duration` property (represented in milliseconds). You can also
# configure the transition function by setting the `animation` property.
#
# Values for `animation`:
# - Ease
# - EaseOut
# - EaseOutSine
# - EaseOutQuad
# - EaseOutCubic
# - EaseOutQuart
# - EaseOutQuint
# - EaseOutExpo
# - EaseOutCirc
# - Linear
#
# Specifying a `duration` of `0` will disable the visual bell.
#visual_bell:
# animation: EaseOutExpo
# duration: 0
# color: '#ffffff'
#selection:
#semantic_escape_chars: ",│`|:\"' ()[]{}<>\t"
# When set to `true`, selected text will be copied to the primary clipboard.
#save_to_clipboard: false
# Allow terminal applications to change Alacritty's window title.
#dynamic_title: true
#cursor:
# Cursor style
#
# Values for `style`:
# - ▇ Block
# - _ Underline
# - | Beam
#style: Block
# If this is `true`, the cursor will be rendered as a hollow box when the
# window is not focused.
#unfocused_hollow: true
# Live config reload (changes require restart)
#live_config_reload: true
# Shell
#
# You can set `shell.program` to the path of your favorite shell, e.g. `/bin/fish`.
# Entries in `shell.args` are passed unmodified as arguments to the shell.
#
# Default:
# - (macOS) /bin/bash --login
# - (Linux/BSD) user login shell
# - (Windows) powershell
#shell:
# program: /bin/bash
# args:
# - --login
# Startup directory
#
# Directory the shell is started in. If this is unset, or `None`, the working
# directory of the parent process will be used.
#working_directory: None
# WinPTY backend (Windows only)
#
# Alacritty defaults to using the newer ConPTY backend if it is available,
# since it resolves a lot of bugs and is quite a bit faster. If it is not
# available, the the WinPTY backend will be used instead.
#
# Setting this option to `true` makes Alacritty use the legacy WinPTY backend,
# even if the ConPTY backend is available.
#winpty_backend: false
# Send ESC (\x1b) before characters when alt is pressed.
#alt_send_esc: true
#debug:
# Display the time it takes to redraw each frame.
#render_timer: false
# Keep the log file after quitting Alacritty.
#persistent_logging: false
# Log level
#
# Values for `log_level`:
# - None
# - Error
# - Warn
# - Info
# - Debug
# - Trace
#log_level: Warn
# Print all received window events.
#print_events: false
# Record all characters and escape sequences as test data.
#ref_test: false
#mouse:
# Click settings
#
# The `double_click` and `triple_click` settings control the time
# alacritty should wait for accepting multiple clicks as one double
# or triple click.
#double_click: { threshold: 300 }
#triple_click: { threshold: 300 }
# If this is `true`, the cursor is temporarily hidden when typing.
#hide_when_typing: false
#url:
# URL launcher
#
# This program is executed when clicking on a text which is recognized as a URL.
# The URL is always added to the command as the last parameter.
#
# When set to `None`, URL launching will be disabled completely.
#
# Default:
# - (macOS) open
# - (Linux/BSD) xdg-open
# - (Windows) explorer
#launcher:
# program: xdg-open
# args: []
# URL modifiers
#
# These are the modifiers that need to be held down for opening URLs when clicking
# on them. The available modifiers are documented in the key binding section.
#modifiers: None
# Mouse bindings
#
# Mouse bindings are specified as a list of objects, much like the key
# bindings further below.
#
# Each mouse binding will specify a:
#
# - `mouse`:
#
# - Middle
# - Left
# - Right
# - Numeric identifier such as `5`
#
# - `action` (see key bindings)
#
# And optionally:
#
# - `mods` (see key bindings)
#mouse_bindings:
# - { mouse: Middle, action: PasteSelection }
# Key bindings
#
# Key bindings are specified as a list of objects. For example, this is the
# default paste binding:
#
# `- { key: V, mods: Control|Shift, action: Paste }`
#
# Each key binding will specify a:
#
# - `key`: Identifier of the key pressed
#
# - A-Z
# - F1-F24
# - Key0-Key9
#
# A full list with available key codes can be found here:
# https://docs.rs/glutin/*/glutin/event/enum.VirtualKeyCode.html#variants
#
# Instead of using the name of the keys, the `key` field also supports using
# the scancode of the desired key. Scancodes have to be specified as a
# decimal number. This command will allow you to display the hex scancodes
# for certain keys:
#
# `showkey --scancodes`.
#
# Then exactly one of:
#
# - `chars`: Send a byte sequence to the running application
#
# The `chars` field writes the specified string to the terminal. This makes
# it possible to pass escape sequences. To find escape codes for bindings
# like `PageUp` (`"\x1b[5~"`), you can run the command `showkey -a` outside
# of tmux. Note that applications use terminfo to map escape sequences back
# to keys. It is therefore required to update the terminfo when changing an
# escape sequence.
#
# - `action`: Execute a predefined action
#
# - Copy
# - Paste
# - PasteSelection
# - IncreaseFontSize
# - DecreaseFontSize
# - ResetFontSize
# - ScrollPageUp
# - ScrollPageDown
# - ScrollLineUp
# - ScrollLineDown
# - ScrollToTop
# - ScrollToBottom
# - ClearHistory
# - Hide
# - Minimize
# - Quit
# - ToggleFullscreen
# - SpawnNewInstance
# - ClearLogNotice
# - ReceiveChar
# - None
#
# (macOS only):
# - ToggleSimpleFullscreen: Enters fullscreen without occupying another space
#
# - `command`: Fork and execute a specified command plus arguments
#
# The `command` field must be a map containing a `program` string and an
# `args` array of command line parameter strings. For example:
# `{ program: "alacritty", args: ["-e", "vttest"] }`
#
# And optionally:
#
# - `mods`: Key modifiers to filter binding actions
#
# - Command
# - Control
# - Option
# - Super
# - Shift
# - Alt
#
# Multiple `mods` can be combined using `|` like this:
# `mods: Control|Shift`.
# Whitespace and capitalization are relevant and must match the example.
#
# - `mode`: Indicate a binding for only specific terminal reported modes
#
# This is mainly used to send applications the correct escape sequences
# when in different modes.
#
# - AppCursor
# - AppKeypad
# - Alt
#
# A `~` operator can be used before a mode to apply the binding whenever
# the mode is *not* active, e.g. `~Alt`.
#
# Bindings are always filled by default, but will be replaced when a new
# binding with the same triggers is defined. To unset a default binding, it can
# be mapped to the `ReceiveChar` action. Alternatively, you can use `None` for
# a no-op if you do not wish to receive input characters for that binding.
key_bindings:
# (Windows, Linux, and BSD only)
- { key: V, mods: Control|Shift, action: Paste }
- { key: C, mods: Control|Shift, action: Copy }
- { key: Insert, mods: Shift, action: PasteSelection }
- { key: Key0, mods: Control, action: ResetFontSize }
- { key: Equals, mods: Control, action: IncreaseFontSize }
- { key: Plus, mods: Control, action: IncreaseFontSize }
- { key: Minus, mods: Control, action: DecreaseFontSize }
- { key: F11, mods: None, action: ToggleFullscreen }
- { key: Paste, mods: None, action: Paste }
- { key: Copy, mods: None, action: Copy }
- { key: L, mods: Control, action: ClearLogNotice }
- { key: L, mods: Control, chars: "\x0c" }
- { key: PageUp, mods: None, action: ScrollPageUp, mode: ~Alt }
- { key: PageDown, mods: None, action: ScrollPageDown, mode: ~Alt }
- { key: Home, mods: Shift, action: ScrollToTop, mode: ~Alt }
- { key: End, mods: Shift, action: ScrollToBottom, mode: ~Alt }

@ -0,0 +1,20 @@
font:
normal:
family: Source Code Pro
style: Regular
bold:
family: Source Code Pro
style: Bold
italic:
family: Source Code Pro
style: Italic
bold_italic:
family: Source Code Pro
style: Bold Italic
size: 8

@ -0,0 +1,45 @@
if status is-interactive
# Commands to run in interactive sessions can go here
end
set fish_greeting # Supresses fish's intro message
set TERM "xterm-256color" # Defines th terminal type
#####################
### VISUALS BEGIN ###
#####################
set fish_color_normal brcyan
set fish_color_autosuggestion '#7d7d7d'
set fish_color_command brcyan
set fish_color_error '#ff6c6b'
set fish_color_param brcyan
#####################
### VISUALS END ###
#####################
# Changing "ls" to "exa"
alias ls='exa --color=always --group-directories-first' # my preferred listing
alias lsl='exa -al --color=always --group-directories-first' # my preferred listing
alias la='exa -a --color=always --group-directories-first' # all files and dirs
alias ll='exa -l --color=always --group-directories-first' # long format
alias lt='exa -aT --color=always --group-directories-first' # tree listing
alias l.='exa -a | egrep "^\."'
# navigation
alias ..='cd ..'
alias ...='cd ../..'
#adding flags
alias df='df -h' # human-readable sizes
alias free='free -m' # show sizes in MB
#aliseption
alias alias_edit='vim ~/.config/fish/config.fish'
alias alias_activate='source ~/.config/fish/config.fish'
#####################
### ALIASES END ###
#####################

@ -0,0 +1,428 @@
#################################
# Shadows #
#################################
# Enabled client-side shadows on windows. Note desktop windows
# (windows with '_NET_WM_WINDOW_TYPE_DESKTOP') never get shadow,
# unless explicitly requested using the wintypes option.
#
# shadow = false
shadow = true;
# The blur radius for shadows, in pixels. (defaults to 12)
# shadow-radius = 12
shadow-radius = 7;
# The opacity of shadows. (0.0 - 1.0, defaults to 0.75)
# shadow-opacity = .75
# The left offset for shadows, in pixels. (defaults to -15)
# shadow-offset-x = -15
shadow-offset-x = -7;
# The top offset for shadows, in pixels. (defaults to -15)
# shadow-offset-y = -15
shadow-offset-y = -7;
# Red color value of shadow (0.0 - 1.0, defaults to 0).
# shadow-red = 0
# Green color value of shadow (0.0 - 1.0, defaults to 0).
# shadow-green = 0
# Blue color value of shadow (0.0 - 1.0, defaults to 0).
# shadow-blue = 0
# Hex string color value of shadow (#000000 - #FFFFFF, defaults to #000000). This option will override options set shadow-(red/green/blue)
# shadow-color = "#000000"
# Specify a list of conditions of windows that should have no shadow.
#
# examples:
# shadow-exclude = "n:e:Notification";
#
# shadow-exclude = []
shadow-exclude = [
"name = 'Notification'",
"class_g = 'Conky'",
"class_g ?= 'Notify-osd'",
"class_g = 'Cairo-clock'",
"_GTK_FRAME_EXTENTS@:c"
];
# Specify a list of conditions of windows that should have no shadow painted over, such as a dock window.
# clip-shadow-above = []
# Specify a X geometry that describes the region in which shadow should not
# be painted in, such as a dock window region. Use
# shadow-exclude-reg = "x10+0+0"
# for example, if the 10 pixels on the bottom of the screen should not have shadows painted on.
#
# shadow-exclude-reg = ""
# Crop shadow of a window fully on a particular Xinerama screen to the screen.
# xinerama-shadow-crop = false
#################################
# Fading #
#################################
# Fade windows in/out when opening/closing and when opacity changes,
# unless no-fading-openclose is used.
# fading = false
fading = true;
# Opacity change between steps while fading in. (0.01 - 1.0, defaults to 0.028)
# fade-in-step = 0.028
fade-in-step = 0.03;
# Opacity change between steps while fading out. (0.01 - 1.0, defaults to 0.03)
# fade-out-step = 0.03
fade-out-step = 0.03;
# The time between steps in fade step, in milliseconds. (> 0, defaults to 10)
# fade-delta = 10
# Specify a list of conditions of windows that should not be faded.
# fade-exclude = []
# Do not fade on window open/close.
# no-fading-openclose = false
# Do not fade destroyed ARGB windows with WM frame. Workaround of bugs in Openbox, Fluxbox, etc.
# no-fading-destroyed-argb = false
#################################
# Transparency / Opacity #
#################################
# Opacity of inactive windows. (0.1 - 1.0, defaults to 1.0)
# inactive-opacity = 1
inactive-opacity = 0.95;
# Opacity of window titlebars and borders. (0.1 - 1.0, disabled by default)
# frame-opacity = 1.0
frame-opacity = 0.9;
# Let inactive opacity set by -i override the '_NET_WM_WINDOW_OPACITY' values of windows.
# inactive-opacity-override = true
inactive-opacity-override = false;
# Default opacity for active windows. (0.0 - 1.0, defaults to 1.0)
# active-opacity = 1.0
# Dim inactive windows. (0.0 - 1.0, defaults to 0.0)
# inactive-dim = 0.0
# Specify a list of conditions of windows that should never be considered focused.
# focus-exclude = []
focus-exclude = [ "class_g = 'Cairo-clock'" ];
# Use fixed inactive dim value, instead of adjusting according to window opacity.
# inactive-dim-fixed = 1.0
# Specify a list of opacity rules, in the format `PERCENT:PATTERN`,
# like `50:name *= "Firefox"`. picom-trans is recommended over this.
# Note we don't make any guarantee about possible conflicts with other
# programs that set '_NET_WM_WINDOW_OPACITY' on frame or client windows.
# example:
# opacity-rule = [ "80:class_g = 'URxvt'" ];
#
# opacity-rule = []
#################################
# Corners #
#################################
# Sets the radius of rounded window corners. When > 0, the compositor will
# round the corners of windows. Does not interact well with
# `transparent-clipping`.
corner-radius = 5
# Exclude conditions for rounded corners.
rounded-corners-exclude = [
"window_type = 'dock'",
"window_type = 'desktop'"
];
#################################
# Background-Blurring #
#################################
# Parameters for background blurring, see the *BLUR* section for more information.
# blur-method =
# blur-size = 12
#
# blur-deviation = false
#
blur-strength = 5
# Blur background of semi-transparent / ARGB windows.
# Bad in performance, with driver-dependent behavior.
# The name of the switch may change without prior notifications.
#
# blur-background = false
# Blur background of windows when the window frame is not opaque.
# Implies:
# blur-background
# Bad in performance, with driver-dependent behavior. The name may change.
#
# blur-background-frame = false
# Use fixed blur strength rather than adjusting according to window opacity.
# blur-background-fixed = false
# Specify the blur convolution kernel, with the following format:
# example:
# blur-kern = "5,5,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1";
#
# blur-kern = ""
blur-kern = "3x3box";
# Exclude conditions for background blur.
# blur-background-exclude = []
blur-background-exclude = [
"window_type = 'dock'",
"window_type = 'desktop'",
"_GTK_FRAME_EXTENTS@:c"
];
#################################
# General Settings #
#################################
# Enable remote control via D-Bus. See the man page for more details.
# dbus = true
# Daemonize process. Fork to background after initialization. Causes issues with certain (badly-written) drivers.
# daemon = false
# Specify the backend to use: `xrender`, `glx`, or `xr_glx_hybrid`.
# `xrender` is the default one.
#
# backend = "glx"
backend = "xrender";
# Enable/disable VSync.
# vsync = false
vsync = true;
# Enable remote control via D-Bus. See the *D-BUS API* section below for more details.
# dbus = false
# Try to detect WM windows (a non-override-redirect window with no
# child that has 'WM_STATE') and mark them as active.
#
# mark-wmwin-focused = false
mark-wmwin-focused = true;
# Mark override-redirect windows that doesn't have a child window with 'WM_STATE' focused.
# mark-ovredir-focused = false
mark-ovredir-focused = true;
# Try to detect windows with rounded corners and don't consider them
# shaped windows. The accuracy is not very high, unfortunately.
#
# detect-rounded-corners = false
detect-rounded-corners = true;
# Detect '_NET_WM_WINDOW_OPACITY' on client windows, useful for window managers
# not passing '_NET_WM_WINDOW_OPACITY' of client windows to frame windows.
#
# detect-client-opacity = false
detect-client-opacity = true;
# Use EWMH '_NET_ACTIVE_WINDOW' to determine currently focused window,
# rather than listening to 'FocusIn'/'FocusOut' event. Might have more accuracy,
# provided that the WM supports it.
#
# use-ewmh-active-win = false
# Unredirect all windows if a full-screen opaque window is detected,
# to maximize performance for full-screen windows. Known to cause flickering
# when redirecting/unredirecting windows.
#
# unredir-if-possible = false
# Delay before unredirecting the window, in milliseconds. Defaults to 0.
# unredir-if-possible-delay = 0
# Conditions of windows that shouldn't be considered full-screen for unredirecting screen.
# unredir-if-possible-exclude = []
# Use 'WM_TRANSIENT_FOR' to group windows, and consider windows
# in the same group focused at the same time.
#
# detect-transient = false
detect-transient = true;
# Use 'WM_CLIENT_LEADER' to group windows, and consider windows in the same
# group focused at the same time. This usually means windows from the same application
# will be considered focused or unfocused at the same time.
# 'WM_TRANSIENT_FOR' has higher priority if detect-transient is enabled, too.
#
# detect-client-leader = false
# Resize damaged region by a specific number of pixels.
# A positive value enlarges it while a negative one shrinks it.
# If the value is positive, those additional pixels will not be actually painted
# to screen, only used in blur calculation, and such. (Due to technical limitations,
# with use-damage, those pixels will still be incorrectly painted to screen.)
# Primarily used to fix the line corruption issues of blur,
# in which case you should use the blur radius value here
# (e.g. with a 3x3 kernel, you should use `--resize-damage 1`,
# with a 5x5 one you use `--resize-damage 2`, and so on).
# May or may not work with *--glx-no-stencil*. Shrinking doesn't function correctly.
#
# resize-damage = 1
# Specify a list of conditions of windows that should be painted with inverted color.
# Resource-hogging, and is not well tested.
#
# invert-color-include = []
# GLX backend: Avoid using stencil buffer, useful if you don't have a stencil buffer.
# Might cause incorrect opacity when rendering transparent content (but never
# practically happened) and may not work with blur-background.
# My tests show a 15% performance boost. Recommended.
#
glx-no-stencil = true;
# GLX backend: Avoid rebinding pixmap on window damage.
# Probably could improve performance on rapid window content changes,
# but is known to break things on some drivers (LLVMpipe, xf86-video-intel, etc.).
# Recommended if it works.
#
# glx-no-rebind-pixmap = false
# Disable the use of damage information.
# This cause the whole screen to be redrawn every time, instead of the part of the screen
# has actually changed. Potentially degrades the performance, but might fix some artifacts.
# The opposing option is use-damage
#
# no-use-damage = false
use-damage = true;
# Use X Sync fence to sync clients' draw calls, to make sure all draw
# calls are finished before picom starts drawing. Needed on nvidia-drivers
# with GLX backend for some users.
#
# xrender-sync-fence = false
# GLX backend: Use specified GLSL fragment shader for rendering window
# contents. Read the man page for a detailed explanation of the interface.
#
# window-shader-fg = "default"
# Use rules to set per-window shaders. Syntax is SHADER_PATH:PATTERN, similar
# to opacity-rule. SHADER_PATH can be "default". This overrides window-shader-fg.
#
# window-shader-fg-rule = [
# "my_shader.frag:window_type != 'dock'"
# ]
# Force all windows to be painted with blending. Useful if you
# have a glx-fshader-win that could turn opaque pixels transparent.
#
# force-win-blend = false
# Do not use EWMH to detect fullscreen windows.
# Reverts to checking if a window is fullscreen based only on its size and coordinates.
#
# no-ewmh-fullscreen = false
# Dimming bright windows so their brightness doesn't exceed this set value.
# Brightness of a window is estimated by averaging all pixels in the window,
# so this could comes with a performance hit.
# Setting this to 1.0 disables this behaviour. Requires --use-damage to be disabled. (default: 1.0)
#
# max-brightness = 1.0
# Make transparent windows clip other windows like non-transparent windows do,
# instead of blending on top of them.
#
# transparent-clipping = false
# Specify a list of conditions of windows that should never have transparent
# clipping applied. Useful for screenshot tools, where you need to be able to
# see through transparent parts of the window.
#
# transparent-clipping-exclude = []
# Set the log level. Possible values are:
# "trace", "debug", "info", "warn", "error"
# in increasing level of importance. Case doesn't matter.
# If using the "TRACE" log level, it's better to log into a file
# using *--log-file*, since it can generate a huge stream of logs.
#
# log-level = "debug"
log-level = "warn";
# Set the log file.
# If *--log-file* is never specified, logs will be written to stderr.
# Otherwise, logs will to written to the given file, though some of the early
# logs might still be written to the stderr.
# When setting this option from the config file, it is recommended to use an absolute path.
#
# log-file = "/path/to/your/log/file"
# Show all X errors (for debugging)
# show-all-xerrors = false
# Write process ID to a file.
# write-pid-path = "/path/to/your/log/file"
# Window type settings
#
# 'WINDOW_TYPE' is one of the 15 window types defined in EWMH standard:
# "unknown", "desktop", "dock", "toolbar", "menu", "utility",
# "splash", "dialog", "normal", "dropdown_menu", "popup_menu",
# "tooltip", "notification", "combo", and "dnd".
#
# Following per window-type options are available: ::
#
# fade, shadow:::
# Controls window-type-specific shadow and fade settings.
#
# opacity:::
# Controls default opacity of the window type.
#
# focus:::
# Controls whether the window of this type is to be always considered focused.
# (By default, all window types except "normal" and "dialog" has this on.)
#
# full-shadow:::
# Controls whether shadow is drawn under the parts of the window that you
# normally won't be able to see. Useful when the window has parts of it
# transparent, and you want shadows in those areas.
#
# clip-shadow-above:::
# Controls whether shadows that would have been drawn above the window should
# be clipped. Useful for dock windows that should have no shadow painted on top.
#
# redir-ignore:::
# Controls whether this type of windows should cause screen to become
# redirected again after been unredirected. If you have unredir-if-possible
# set, and doesn't want certain window to cause unnecessary screen redirection,
# you can set this to `true`.
#
wintypes:
{
tooltip = { fade = true; shadow = true; opacity = 0.75; focus = true; full-shadow = false; };
dock = { shadow = false; clip-shadow-above = true; }
dnd = { shadow = false; }
popup_menu = { opacity = 0.8; }
dropdown_menu = { opacity = 0.8; }
};

@ -0,0 +1,2 @@
set -g mouse on

@ -0,0 +1,3 @@
#!/bin/bash
echo $(acpi | grep -o -E '[0-9][0-9]?%|100%')

@ -0,0 +1,64 @@
-- Xmobar (http://projects.haskell.org/xmobar/)
-- This is one of the xmobar configurations for DTOS.
-- This config is packaged in the DTOS repo as 'dtos-xmobar'
-- Color scheme: Doom One
-- Dependencies:
-- otf-font-awesome
-- ttf-mononoki
-- ttf-ubuntu-font-family
-- htop
-- emacs
-- pacman (Arch Linux)
-- trayer
-- 'dtos-local-bin' (from dtos-core-repo)
Config { font = "xft:Ubuntu:weight=bold:pixelsize=11:antialias=true:hinting=true"
, additionalFonts = [ "xft:Mononoki:pixelsize=11:antialias=true:hinting=true"
, "xft:Font Awesome 5 Free Solid:pixelsize=12"
, "xft:Font Awesome 5 Brands:pixelsize=12"
]
, bgColor = "#282c34"
, fgColor = "#ff6c6b"
-- Position TopSize and BottomSize take 3 arguments:
-- an alignment parameter (L/R/C) for Left, Right or Center.
-- an integer for the percentage width, so 100 would be 100%.
-- an integer for the minimum pixel height for xmobar, so 24 would force a height of at least 24 pixels.
-- NOTE: The height should be the same as the trayer (system tray) height.
, position = TopSize L 100 24
, lowerOnStart = True
, hideOnStart = False
, allDesktops = True
, persistent = True
, iconRoot = ".xmonad/xpm/" -- default: "."
, commands = [
-- Echos a "penguin" icon in front of the kernel output.
Run Com "echo" ["<fn=3>\xf17c</fn>"] "penguin" 3600
-- Get kernel version (script found in .local/bin)
, Run Com ".local/bin/kernel" [] "kernel" 36000
-- Cpu usage in percent
, Run Cpu ["-t", "<fn=2>\xf108</fn> cpu: (<total>%)","-H","50","--high","red"] 20
-- Ram used number and percent
, Run Memory ["-t", "<fn=2>\xf233</fn> mem: <used>M (<usedratio>%)"] 20
-- Disk space free
, Run DiskU [("/", "<fn=2>\xf0c7</fn> hdd: <free> free")] [] 60
-- Echos an "up arrow" icon in front of the uptime output.
, Run Com "echo" ["<fn=2>\xf0aa</fn>"] "uparrow" 3600
-- Uptime
, Run Uptime ["-t", "uptime: <days>d <hours>h"] 360
-- Echos a "bell" icon in front of the pacman updates.
, Run Com "echo" ["<fn=2>\xf0f3</fn>"] "bell" 3600
-- Check for pacman updates (script found in .local/bin)
, Run Com ".local/bin/pacupdate" [] "pacupdate" 36000
-- Echos a "battery" icon in front of the pacman updates.
, Run Com "echo" ["<fn=2>\xf242</fn>"] "baticon" 3600
-- Battery
, Run BatteryP ["BAT0"] ["-t", "<acstatus><watts> (<left>%)"] 360
-- Time and date
, Run Date "<fn=2>\xf017</fn> %b %d %Y - (%H:%M) " "date" 50
-- Prints out the left side items such as workspaces, layout, etc.
, Run UnsafeStdinReader
]
, sepChar = "%"
, alignSep = "}{"
, template = " }{ <box type=Bottom width=2 mb=2 color=#51afef><fc=#51afef>%penguin% %kernel%</fc></box> <box type=Bottom width=2 mb=2 color=#ecbe7b><fc=#ecbe7b><action=`alacritty -e htop`>%cpu%</action></fc></box> <box type=Bottom width=2 mb=2 color=#ff6c6b><fc=#ff6c6b><action=`alacritty -e htop`>%memory%</action></fc></box> <box type=Bottom width=2 mb=2 color=#a9a1e1><fc=#a9a1e1>%disku%</fc></box> <box type=Bottom width=2 mb=2 color=#98be65><fc=#98be65>%uparrow% %uptime%</fc></box> <box type=Bottom width=2 mb=2 color=#c678dd><fc=#c678dd>%bell% <action=`alacritty -e sudo pacman -Syu`>%pacupdate%</action></fc></box> <box type=Bottom width=2 mb=2 color=#da8548><fc=#da8548>%baticon% %battery%</fc></box> <box type=Bottom width=2 mb=2 color=#46d9ff><fc=#46d9ff><action=`emacsclient -c -a 'emacs' --eval '(doom/window-maximize-buffer(dt/year-calendar))'`>%date%</action></fc></box> %trayerpad%"
}

@ -0,0 +1,3 @@
#!/bin/bash
uname -r | grep -Eo '[[:digit:]]+[.][[:digit:]]+[.]+[[:digit:]]'

@ -0,0 +1,14 @@
#!/bin/bash
system=$(cat /etc/os-release | sed -n 3p)
if [[ $system == *"arch"* ]]
then
ip=$(ip -json route get 8.8.8.8 | jq -r '.[].prefsrc')
elif [[ $system == *"debian"* ]]
then
ip=$(hostname -I | awk '{print $1}')
fi
echo $ip

@ -0,0 +1,64 @@
Config { font = "xft:Ubuntu:weight=bold:pixelsize=26:antialias=true:hinting=true"
, additionalFonts = [ "xft:Mononoki:pixelsize=18:antialias=true:hinting=true"
, "xft:Font Awesome 6 Free Solid:pixelsize=30"
, "xft:Font Awesome 6 Brands:pixelsize=30"
]
, bgColor = "#282c34"
, fgColor = "#ff6c6b"
, alpha = 255
, position = TopSize L 100 35
, textOffset = -1
, iconOffset = -1
, lowerOnStart = True
, persistent = True
, hideOnStart = False
, iconRoot = "."
, allDesktops = True
, overrideRedirect = True
, commands = [
-- Echos a "penguin" icon in front of the kernel output.
Run Com "echo" ["<fn=3>\xf17c</fn>"] "penguin" 36000
-- Get kernel version (script found in .local/bin)
, Run Com "/home/key/.config/xmobar/get_kernel.sh" [] "kernel" 36000
-- Echos a "rj45" icon in front of the ip output.
, Run Com "echo" ["<fn=2>\xf796</fn>"] "rj" 36000
-- Get the Current IP address
, Run Com "/home/key/.config/xmobar/ip.sh" [] "myip" 150
, Run Com "/home/key/.config/xmobar/battery.sh" [] "battery" 150
-- Dy Newtoek consumption
, Run DynNetwork [ "--template" , "<dev>: <tx>kB/s|<rx>kB/s"
, "--Low" , "5000" -- units: kB/s
, "--High" , "50000" -- units: kB/s
, "--low" , "darkgreen"
, "--normal" , "darkorange"
, "--high" , "darkred"
] 10
-- Cpu usage in percent
, Run Cpu ["-t", "<fn=2>\xf108</fn> cpu: (<total>%)","-H","50","--high","red"] 20
-- Ram used number and percent
, Run Memory ["-t", "<fn=2>\xf233</fn> mem: <used>M (<usedratio>%)"] 20
-- Disk space free
, Run DiskU [("/", "<fn=2>\xf0c7</fn> hdd: <free> free")] [] 60
-- Echos an "up arrow" icon in front of the uptime output.
, Run Com "echo" ["<fn=2>\xf0aa</fn>"] "uparrow" 3600
-- Uptime
, Run Uptime ["-t", "uptime: <days>d <hours>h"] 360
-- Echos a "bell" icon in front of the pacman updates.
, Run Com "echo" ["<fn=2>\xf0f3</fn>"] "bell" 3600
-- Check for pacman updates (script found in .local/bin)
, Run Com ".local/bin/pacupdate" [] "pacupdate" 36000
-- Echos a "battery" icon in front of the pacman updates.
, Run Com "echo" ["<fn=2>\xf242</fn>"] "baticon" 3600
-- Battery
, Run Date "<fn=2>\xf017</fn> %b %d %Y - (%H:%M) " "date" 50
-- Prints out the left side items such as workspaces, layout, etc.
, Run UnsafeStdinReader
]
, sepChar = "%"
, alignSep = "}{"
, template = "<box type=Bottom width=2 mb=2 color=#51afef><fc=#51afef>%penguin% %kernel%</fc></box> <box type=Bottom width=2 mb=2 color=#DA8012><fc=#DA8012> %rj% %dynnetwork% IP:%myip%</fc></box>}<box type=Bottom width=2 mb=2 color=#1259DA><fc=#1259DA>%date%</fc></box>{<box type=Bottom width=2 mb=2 color=#DC143C><fc=#DC143C>%battery% %baticon%</fc></box> <box type=Bottom width=2 mb=2 color=#ecbe7b><fc=#ecbe7b><action=`alacritty -e htop`>%cpu%</action></fc></box> "
}

Binary file not shown.

@ -0,0 +1,313 @@
-- KeY Defined : Imports
import XMonad
import XMonad.Util.EZConfig (additionalKeysP, mkNamedKeymap) -- Vim Style Key defines
import XMonad.Util.Dmenu -- Excatly what it says
import XMonad.Util.Ungrab -- For screenshots
import XMonad.Layout.ThreeColumns -- For big scrrens
import XMonad.Hooks.EwmhDesktops
import XMonad.Layout.Spacing
import XMonad.Layout.LayoutModifier
import XMonad.Layout.Gaps
-- Default defined
import Data.Monoid
import System.Exit
import XMonad.Layout.NoBorders
import XMonad.Hooks.ManageDocks
import XMonad.Hooks.ManageHelpers
import XMonad.Util.Run
import XMonad.Util.SpawnOnce
import XMonad.Actions.Navigation2D
import XMonad.Util.NamedActions
import Data.Maybe (fromJust)
import XMonad.Layout.ShowWName
import XMonad.Layout.ThreeColumns
import qualified XMonad.StackSet as W
import qualified Data.Map as M
-- KeY Defined : Terminal
myTerminal :: String
myTerminal = "alacritty"
-- KeY Defined : Shell interpreter
myShell :: String
myShell = "fish"
-- KeY Defined default web browser the sapce at the end is important.
myBrowser :: String
myBrowser = "qutebrowser "
-- KeY Defined default App Launcher.
myLauncher :: String
myLauncher = "dmenu_run "
-- KeY Defined Whether focus follows the mouse pointer.
myFocusFollowsMouse :: Bool
myFocusFollowsMouse = True
-- KeY Defined : Whether clicking on a window to focus also passes the click to the window
myClickJustFocuses :: Bool
myClickJustFocuses = False
-- KeY Defined : Width of the window border in pixels.
myBorderWidth = 3
-- KeY Defined : "windows key" = mod4Mask.
myModMask = mod4Mask
-- myWorkspaces = [" 1 ", " 2 ", " 3 ", " 4 ", " 5 ", " 6 ", " 7 ", " 8 ", " 9 "]
myWorkspaces = [" dev ", " www ", " sys ", " doc ", " vbox ", " chat ", " mus ", " vid ", " gfx "]
myWorkspaceIndices = M.fromList $ zipWith (,) myWorkspaces [1..] -- (,) == \x y -> (x,y)
clickable ws = "<action=xdotool key super+"++show i++">"++ws++"</action>"
where i = fromJust $ M.lookup ws myWorkspaceIndices
-- KeY Defined : Border colors for unfocused and focused windows, respectively.
myNormalBorderColor = "#dddddd" -- White
myFocusedBorderColor = "#F000FF" -- Purple
------------------------------------------------------------------------
-- Key Defined : Key bindings. Add, modify or remove key bindings here.
--
myKeys conf@(XConfig {XMonad.modMask = modm}) = M.fromList $
-- KeY Defined : launch default terminal with the default Shell
[ ((modm, xK_Return), spawn $ (myTerminal ++ " -e " ++ myShell))
-- KeY Defined : Volume Up
, ((modm, xK_F3 ), spawn "amixer set Master 2%+")
-- KeY Defined : Volume Up
, ((modm, xK_F2 ), spawn "amixer set Master 2%-")
-- KeY Defined : Toggle mute
, ((modm, xK_F1 ), spawn "amixer -D pulse set Master 1+ toggle")
-- KeY Defined : Launch (p)rogramms
, ((modm, xK_p ), spawn $ (myLauncher))
-- KeY Defined : Launch (i)nternet Explorer
, ((modm, xK_i ), spawn $ (myBrowser))
-- KeY Defined : (c)lose focused window
, ((modm, xK_c ), kill)
-- KeY Defined : Rotate through the available layout algorithms
, ((modm, xK_space ), sendMessage NextLayout)
-- KeY Defined : Reset the layouts on the current workspace to default
, ((modm .|. shiftMask, xK_space ), setLayout $ XMonad.layoutHook conf)
-- KeY Definded : Take A (S)crenn Shot
, ((modm .|. shiftMask, xK_s ), unGrab *> spawn "scrot -s")
-- Resize viewed windows to the correct size
, ((modm, xK_n ), refresh)
-- Move focus to the next window
, ((modm, xK_Tab ), windows W.focusDown)
-- KeY Defined : Move focus to the next window
, ((modm, xK_j ), windows W.focusDown)
-- KeY Defined : Move focus to the previous window
, ((modm, xK_k ), windows W.focusUp )
-- Move focus to the master window
, ((modm, xK_m ), windows W.focusMaster )
-- Swap the focused window and the master window
, ((modm .|. shiftMask, xK_Return), windows W.swapMaster)
-- KeY Defined : Swap the focused window with the next window
, ((modm .|. shiftMask, xK_j ), windows W.swapDown )
-- KeY Defined : Swap the focused window with the previous window
, ((modm .|. shiftMask, xK_k ), windows W.swapUp )
-- KeY Defined : Shrink the master area
, ((modm, xK_h ), sendMessage Shrink)
-- KeY Defined : Expand the master area
, ((modm, xK_l ), sendMessage Expand)
-- Push window back into tiling
, ((modm, xK_t ), withFocused $ windows . W.sink)
-- Increment the number of windows in the master area
, ((modm , xK_comma ), sendMessage (IncMasterN 1))
-- Deincrement the number of windows in the master area
, ((modm , xK_period), sendMessage (IncMasterN (-1)))
-- KeY Defined : (Q)uit xmonad
, ((modm .|. shiftMask, xK_q ), io (exitWith ExitSuccess))
-- KeY Defined : (q) Restart xmonad
, ((modm , xK_q ), spawn "rm -r /home/key/.xmonad ; xmonad --recompile; xmonad --restart; pkill xmobar")
]
++
--
-- mod-[1..9], Switch to workspace N
-- mod-shift-[1..9], Move client to workspace N
--
[((m .|. modm, k), windows $ f i)
| (i, k) <- zip (XMonad.workspaces conf) [xK_1 .. xK_9]
, (f, m) <- [(W.greedyView, 0), (W.shift, shiftMask)]]
++
--
-- mod-{w,e,r}, Switch to physical/Xinerama screens 1, 2, or 3
-- mod-shift-{w,e,r}, Move client to screen 1, 2, or 3
--
[((m .|. modm, key), screenWorkspace sc >>= flip whenJust (windows . f))
| (key, sc) <- zip [xK_w, xK_e, xK_r] [0..]
, (f, m) <- [(W.view, 0), (W.shift, shiftMask)]]
------------------------------------------------------------------------
-- Mouse bindings: default actions bound to mouse events
--
myMouseBindings (XConfig {XMonad.modMask = modm}) = M.fromList $
-- mod-button1, Set the window to floating mode and move by dragging
[ ((modm, button1), (\w -> focus w >> mouseMoveWindow w
>> windows W.shiftMaster))
-- mod-button2, Raise the window to the top of the stack
, ((modm, button2), (\w -> focus w >> windows W.shiftMaster))
-- mod-button3, Set the window to floating mode and resize by dragging
, ((modm, button3), (\w -> focus w >> mouseResizeWindow w
>> windows W.shiftMaster))
-- you may also bind events to the mouse scroll wheel (button4 and button5)
]
------------------------------------------------------------------------
-- Layouts:
-- You can specify and transform your layouts by modifying these values.
-- If you change layout bindings be sure to use 'mod-shift-space' after
-- restarting (with 'mod-q') to reset your layout state to the new
-- defaults, as xmonad preserves your old layout settings by default.
--
-- The available layouts. Note that each layout is separated by |||,
-- which denotes layout choice.
--
myLayout = avoidStruts (tiled ||| Mirror tiled ||| Full)
where
-- default tiling algorithm partitions the screen into two panes
tiled = Tall nmaster delta ratio
-- The default number of windows in the master pane
nmaster = 1
-- Default proportion of screen occupied by master pane
ratio = 1/2
-- Percent of screen to increment by when resizing panes
delta = 3/100
------------------------------------------------------------------------
-- Window rules:
-- Execute arbitrary actions and WindowSet manipulations when managing
-- a new window. You can use this to, for example, always float a
-- particular program, or have a client always appear on a particular
-- workspace.
--
-- To find the property name associated with a program, use
-- > xprop | grep WM_CLASS
-- and click on the client you're interested in.
--
-- To match on the WM_NAME, you can use 'title' in the same way that
-- 'className' and 'resource' are used below.
--
-- KeY Defined
myManageHook = composeAll
[ className =? "MPlayer" --> doFloat
, className =? "Gimp" --> doFloat
, className =? "Steam" --> doFullFloat
, className =? "factorio" --> doFullFloat
, className =? "TerraTechLinux64.x86_64" --> doFullFloat
, resource =? "desktop_window" --> doIgnore
, resource =? "kdesktop" --> doIgnore
, manageDocks
]
------------------------------------------------------------------------
-- Event handling
-- * EwmhDesktops users should change this to ewmhDesktopsEventHook
--
-- Defines a custom handler function for X Events. The function should
-- return (All True) if the default handler is to be run afterwards. To
-- combine event hooks use mappend or mconcat from Data.Monoid.
--
myEventHook = mempty
------------------------------------------------------------------------
-- Status bars and logging
-- Perform an arbitrary action on each internal state change or X event.
-- See the 'XMonad.Hooks.DynamicLog' extension for examples.
--
myLogHook = mempty
------------------------------------------------------------------------
-- Startup hook
-- Perform an arbitrary action each time xmonad starts or is restarted
-- with mod-q. Used by, e.g., XMonad.Layout.PerWorkspace to initialize
-- per-workspace layout choices.
--
-- By default, do nothing.
myStartupHook = do
spawnOnce "compton &"
spawnOnce "feh --bg-fill --randomize $HOME/wallpaper/* &"
------------------------------------------------------------------------
-- Now run xmonad with all the defaults we set up.
-- Run xmonad with the settings you specify. No need to modify this.
--
main :: IO ()
main = do
xmproc <- spawnPipe ("xmobar $HOME/.config/xmobar/xmobarrc.hs")
xmonad $ docks defaults
-- A structure containing your configuration settings, overriding
-- fields in the default config. Any you don't override, will
-- use the defaults defined in xmonad/XMonad/Config.hs
--
-- No need to modify this.
--
defaults = def {
-- simple stuff
terminal = myTerminal,
focusFollowsMouse = myFocusFollowsMouse,
clickJustFocuses = myClickJustFocuses,
borderWidth = myBorderWidth,
modMask = myModMask,
workspaces = myWorkspaces,
normalBorderColor = myNormalBorderColor,
focusedBorderColor = myFocusedBorderColor,
-- key bindings
keys = myKeys,
mouseBindings = myMouseBindings,
-- hooks, layouts
layoutHook = spacingRaw True (Border 0 5 5 5) True (Border 5 5 5 5) True $ myLayout,
manageHook = myManageHook,
handleEventHook = myEventHook,
logHook = myLogHook,
startupHook = myStartupHook
}

@ -0,0 +1,16 @@
#!/bin/bash
source common.sh
sudo $installCMD cmake pkg-config libfreetype6-dev libfontconfig1-dev libxcb-xfixes0-dev libxkbcommon-dev
git clone https://github.com/alacritty/alacritty.git
sudo curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
source $HOME/.cargo/env
cd alacritty/
cargo build --release -j16
sudo cp target/release/alacritty /usr/local/bin
sudo cp extra/logo/alacritty-term.svg /usr/share/pixmaps/Alacritty.svg
cd ..
sudo rm -r alacritty/
cp -r $main_dir/dotfiles/alacritty /home/$USER/.config/

@ -0,0 +1,4 @@
#!/bin/bash
source common.sh
yay brave-bin

@ -0,0 +1,64 @@
#!/bin/bash
version="5.2"
fontSize=0
dmenu_set_font_size()
{
color_start "themeUserINput"
read -p "What siez fint would you like (6 to 34): " fontSize
color_stop
sed -i -e "s/size=../size=$fontSize/g" config.h
}
intro()
{
cd $MAIN_DIR/programs/dmenu/dmenu_$version/
color_start "themeInstall"
echo ""
echo "Dmenu verison : $version Will be installed"
color_stop
color_start "themeIndication"
echo "Currently used mods are :"
ls | grep -oP '.*diff'
color_stop
}
outro()
{
color_start "themeInstall"
echo "Dmenu installation complete"
echo ""
color_stop
cd $MAIN_DIR
}
install_dmenu()
{
intro
case $OS in
debian)
dmenu_set_font_size
sudo make install
;;
arch)
dmenu_set_font_size
sudo make install
;;
rasberry)
dmenu_set_font_size
sudo make install
;;
*)
echo -n "Invalid os is selectred ofr Dmenu"
exit_abord
;;
esac
outro
}

@ -0,0 +1,64 @@
# dmenu - dynamic menu
# See LICENSE file for copyright and license details.
include config.mk
SRC = drw.c dmenu.c stest.c util.c
OBJ = $(SRC:.c=.o)
all: options dmenu stest
options:
@echo dmenu build options:
@echo "CFLAGS = $(CFLAGS)"
@echo "LDFLAGS = $(LDFLAGS)"
@echo "CC = $(CC)"
.c.o:
$(CC) -c $(CFLAGS) $<
config.h:
cp config.def.h $@
$(OBJ): arg.h config.h config.mk drw.h
dmenu: dmenu.o drw.o util.o
$(CC) -o $@ dmenu.o drw.o util.o $(LDFLAGS)
stest: stest.o
$(CC) -o $@ stest.o $(LDFLAGS)
clean:
rm -f dmenu stest $(OBJ) dmenu-$(VERSION).tar.gz
dist: clean
mkdir -p dmenu-$(VERSION)
cp LICENSE Makefile README arg.h config.def.h config.mk dmenu.1\
drw.h util.h dmenu_path dmenu_run stest.1 $(SRC)\
dmenu-$(VERSION)
tar -cf dmenu-$(VERSION).tar dmenu-$(VERSION)
gzip dmenu-$(VERSION).tar
rm -rf dmenu-$(VERSION)
install: all
mkdir -p $(DESTDIR)$(PREFIX)/bin
cp -f dmenu dmenu_path dmenu_run stest $(DESTDIR)$(PREFIX)/bin
chmod 755 $(DESTDIR)$(PREFIX)/bin/dmenu
chmod 755 $(DESTDIR)$(PREFIX)/bin/dmenu_path
chmod 755 $(DESTDIR)$(PREFIX)/bin/dmenu_run
chmod 755 $(DESTDIR)$(PREFIX)/bin/stest
mkdir -p $(DESTDIR)$(MANPREFIX)/man1
sed "s/VERSION/$(VERSION)/g" < dmenu.1 > $(DESTDIR)$(MANPREFIX)/man1/dmenu.1
sed "s/VERSION/$(VERSION)/g" < stest.1 > $(DESTDIR)$(MANPREFIX)/man1/stest.1
chmod 644 $(DESTDIR)$(MANPREFIX)/man1/dmenu.1
chmod 644 $(DESTDIR)$(MANPREFIX)/man1/stest.1
uninstall:
rm -f $(DESTDIR)$(PREFIX)/bin/dmenu\
$(DESTDIR)$(PREFIX)/bin/dmenu_path\
$(DESTDIR)$(PREFIX)/bin/dmenu_run\
$(DESTDIR)$(PREFIX)/bin/stest\
$(DESTDIR)$(MANPREFIX)/man1/dmenu.1\
$(DESTDIR)$(MANPREFIX)/man1/stest.1
.PHONY: all options clean dist install uninstall

@ -0,0 +1,49 @@
/*
* Copy me if you can.
* by 20h
*/
#ifndef ARG_H__
#define ARG_H__
extern char *argv0;
/* use main(int argc, char *argv[]) */
#define ARGBEGIN for (argv0 = *argv, argv++, argc--;\
argv[0] && argv[0][0] == '-'\
&& argv[0][1];\
argc--, argv++) {\
char argc_;\
char **argv_;\
int brk_;\
if (argv[0][1] == '-' && argv[0][2] == '\0') {\
argv++;\
argc--;\
break;\
}\
for (brk_ = 0, argv[0]++, argv_ = argv;\
argv[0][0] && !brk_;\
argv[0]++) {\
if (argv_ != argv)\
break;\
argc_ = argv[0][0];\
switch (argc_)
#define ARGEND }\
}
#define ARGC() argc_
#define EARGF(x) ((argv[0][1] == '\0' && argv[1] == NULL)?\
((x), abort(), (char *)0) :\
(brk_ = 1, (argv[0][1] != '\0')?\
(&argv[0][1]) :\
(argc--, argv++, argv[0])))
#define ARGF() ((argv[0][1] == '\0' && argv[1] == NULL)?\
(char *)0 :\
(brk_ = 1, (argv[0][1] != '\0')?\
(&argv[0][1]) :\
(argc--, argv++, argv[0])))
#endif

@ -0,0 +1,40 @@
/* See LICENSE file for copyright and license details. */
/* Default settings; can be overriden by command line. */
static int topbar = 1; /* -b option; if 0, dmenu appears at bottom */
static int centered = 0; /* -c option; centers dmenu on screen */
static int min_width = 500; /* minimum width when centered */
/* -fn option overrides fonts[0]; default X11 font or font set */
static const char *fonts[] = {
"monospace:size=10"
};
static const char *prompt = NULL; /* -p option; prompt to the left of input field */
static const char *colors[SchemeLast][2] = {
/* fg bg */
[SchemeNorm] = { "#bbbbbb", "#222222" },
[SchemeSel] = { "#eeeeee", "#005577" },
[SchemeSelHighlight] = { "#ffc978", "#005577" },
[SchemeNormHighlight] = { "#ffc978", "#222222" },
[SchemeOut] = { "#000000", "#00ffff" },
};
static const unsigned int alphas[SchemeLast][2] = {
[SchemeNorm] = { OPAQUE, alpha },
[SchemeSel] = { OPAQUE, alpha },
[SchemeOut] = { OPAQUE, alpha },
};
/* -l option; if nonzero, dmenu uses vertical list with given number of lines */
static unsigned int lines = 0;
/* -h option; minimum height of a menu line */
static unsigned int lineheight = 0;
static unsigned int min_lineheight = 8;
/*
* Characters not considered part of a word while deleting words
* for example: " /?\"&[]"
*/
static const char worddelimiters[] = " ";
/* Size of the window border */
static const unsigned int border_width = 5;

@ -0,0 +1,33 @@
/* See LICENSE file for copyright and license details. */
/* Default settings; can be overriden by command line. */
static int topbar = 1; /* -b option; if 0, dmenu appears at bottom */
static int centered = 0; /* -c option; centers dmenu on screen */
static int min_width = 500; /* minimum width when centered */
/* -fn option overrides fonts[0]; default X11 font or font set */
static const char *fonts[] = {
"monospace:size=10"
};
static const char *prompt = NULL; /* -p option; prompt to the left of input field */
static const char *colors[SchemeLast][2] = {
/* fg bg */
[SchemeNorm] = { "#bbbbbb", "#222222" },
[SchemeSel] = { "#eeeeee", "#005577" },
[SchemeSelHighlight] = { "#ffc978", "#005577" },
[SchemeNormHighlight] = { "#ffc978", "#222222" },
[SchemeOut] = { "#000000", "#00ffff" },
};
/* -l option; if nonzero, dmenu uses vertical list with given number of lines */
static unsigned int lines = 0;
/* -h option; minimum height of a menu line */
static unsigned int lineheight = 0;
static unsigned int min_lineheight = 8;
/*
* Characters not considered part of a word while deleting words
* for example: " /?\"&[]"
*/
static const char worddelimiters[] = " ";
/* Size of the window border */
static const unsigned int border_width = 5;

@ -0,0 +1,10 @@
--- config.def.h
+++ config.def.h
@@ -2,6 +2,7 @@
/* Default settings; can be overriden by command line. */
static int topbar = 1; /* -b option; if 0, dmenu appears at bottom */
+static const unsigned int alpha = 0xf0;
/* -fn option overrides fonts[0]; default X11 font or font set */
static const char *fonts[] = {
"monospace:size=10"

@ -0,0 +1,41 @@
/* See LICENSE file for copyright and license details. */
/* Default settings; can be overriden by command line. */
static int topbar = 1; /* -b option; if 0, dmenu appears at bottom */
static const unsigned int alpha = 0xf0;
/* -fn option overrides fonts[0]; default X11 font or font set */
static const char *fonts[] = {
//"monospace:size=24
"xft:Ubuntu:weight=bold:pixelsize=24antialias=true:hinting=true"
};
static const char *prompt = NULL; /* -p option; prompt to the left of input field */
static const unsigned int alphas[SchemeLast][2] = {
[SchemeNorm] = { OPAQUE, alpha },
[SchemeSel] = { OPAQUE, alpha },
[SchemeOut] = { OPAQUE, alpha },
};
static const char *colors[SchemeLast][2] = {
/* fg bg */
[SchemeNorm] = { "#F7774C", "#002b36" },
[SchemeSel] = { "#F7774C", "#073642"},
[SchemeOut] = { "#000000", "#00ffff" },
[SchemeSelHighlight] = { "#ffc978", "#005577" },
[SchemeNormHighlight] = { "#ffc978", "#222222" },
};
/* -l option; if nonzero, dmenu uses vertical list with given number of lines */
static unsigned int lines = 20;
static const unsigned int border_width = 5;
static unsigned int lineheight = 32;
static unsigned int min_lineheight = 8;
static int centered = 1; /* -c option; centers dmenu on screen */
static int min_width = 1000;
/*
* Characters not considered part of a word while deleting words
* for example: " /?\"&[]"
*/
static const char worddelimiters[] = " ";

@ -0,0 +1,32 @@
# dmenu version
VERSION = 5.2
# paths
PREFIX = /usr/local
MANPREFIX = $(PREFIX)/share/man
X11INC = /usr/X11R6/include
X11LIB = /usr/X11R6/lib
# Xinerama, comment if you don't want it
XINERAMALIBS = -lXinerama
XINERAMAFLAGS = -DXINERAMA
# freetype
FREETYPELIBS = -lfontconfig -lXft
FREETYPEINC = /usr/include/freetype2
# OpenBSD (uncomment)
#FREETYPEINC = $(X11INC)/freetype2
#MANPREFIX = ${PREFIX}/man
# includes and libs
INCS = -I$(X11INC) -I$(FREETYPEINC)
LIBS = -L$(X11LIB) -lX11 -lXrender $(XINERAMALIBS) $(FREETYPELIBS)
# flags
CPPFLAGS = -D_DEFAULT_SOURCE -D_BSD_SOURCE -D_XOPEN_SOURCE=700 -D_POSIX_C_SOURCE=200809L -DVERSION=\"$(VERSION)\" $(XINERAMAFLAGS)
CFLAGS = -std=c99 -pedantic -Wall -Os $(INCS) $(CPPFLAGS)
LDFLAGS = $(LIBS)
# compiler and linker
CC = cc

@ -0,0 +1,267 @@
diff --git a/config.def.h b/config.def.h
index 1edb647..697d511 100644
--- a/config.def.h
+++ b/config.def.h
@@ -2,6 +2,7 @@
/* Default settings; can be overriden by command line. */
static int topbar = 1; /* -b option; if 0, dmenu appears at bottom */
+static const unsigned int alpha = 0xf0;
/* -fn option overrides fonts[0]; default X11 font or font set */
static const char *fonts[] = {
"monospace:size=10"
@@ -13,6 +14,13 @@ static const char *colors[SchemeLast][2] = {
[SchemeSel] = { "#eeeeee", "#005577" },
[SchemeOut] = { "#000000", "#00ffff" },
};
+
+static const unsigned int alphas[SchemeLast][2] = {
+ [SchemeNorm] = { OPAQUE, alpha },
+ [SchemeSel] = { OPAQUE, alpha },
+ [SchemeOut] = { OPAQUE, alpha },
+};
+
/* -l option; if nonzero, dmenu uses vertical list with given number of lines */
static unsigned int lines = 0;
diff --git a/dmenu.c b/dmenu.c
index 65f25ce..3e56e1a 100644
--- a/dmenu.c
+++ b/dmenu.c
@@ -10,6 +10,7 @@
#include <X11/Xlib.h>
#include <X11/Xatom.h>
+#include <X11/Xproto.h>
#include <X11/Xutil.h>
#ifdef XINERAMA
#include <X11/extensions/Xinerama.h>
@@ -25,6 +26,8 @@
#define LENGTH(X) (sizeof X / sizeof X[0])
#define TEXTW(X) (drw_fontset_getwidth(drw, (X)) + lrpad)
+#define OPAQUE 0xffU
+
/* enums */
enum { SchemeNorm, SchemeSel, SchemeOut, SchemeLast }; /* color schemes */
@@ -53,10 +56,16 @@ static XIC xic;
static Drw *drw;
static Clr *scheme[SchemeLast];
+static int useargb = 0;
+static Visual *visual;
+static int depth;
+static Colormap cmap;
+
#include "config.h"
static int (*fstrncmp)(const char *, const char *, size_t) = strncmp;
static char *(*fstrstr)(const char *, const char *) = strstr;
+static void xinitvisual();
static void
appenditem(struct item *item, struct item **list, struct item **last)
@@ -602,7 +611,7 @@ setup(void)
#endif
/* init appearance */
for (j = 0; j < SchemeLast; j++)
- scheme[j] = drw_scm_create(drw, colors[j], 2);
+ scheme[j] = drw_scm_create(drw, colors[j], alphas[i], 2);
clip = XInternAtom(dpy, "CLIPBOARD", False);
utf8 = XInternAtom(dpy, "UTF8_STRING", False);
@@ -640,6 +649,7 @@ setup(void)
x = info[i].x_org;
y = info[i].y_org + (topbar ? 0 : info[i].height - mh);
mw = info[i].width;
+
XFree(info);
} else
#endif
@@ -657,11 +667,13 @@ setup(void)
/* create menu window */
swa.override_redirect = True;
- swa.background_pixel = scheme[SchemeNorm][ColBg].pixel;
+ swa.background_pixel = 0;
+ swa.border_pixel = 0;
+ swa.colormap = cmap;
swa.event_mask = ExposureMask | KeyPressMask | VisibilityChangeMask;
- win = XCreateWindow(dpy, parentwin, x, y, mw, mh, 0,
- CopyFromParent, CopyFromParent, CopyFromParent,
- CWOverrideRedirect | CWBackPixel | CWEventMask, &swa);
+ win = XCreateWindow(dpy, parentwin, x, y, mw, mh, border_width,
+ depth, CopyFromParent, visual,
+ CWOverrideRedirect | CWBackPixel | CWBorderPixel | CWColormap | CWEventMask, &swa);
XSetClassHint(dpy, win, &ch);
@@ -747,7 +759,8 @@ main(int argc, char *argv[])
if (!XGetWindowAttributes(dpy, parentwin, &wa))
die("could not get embedding window attributes: 0x%lx",
parentwin);
- drw = drw_create(dpy, screen, root, wa.width, wa.height);
+ xinitvisual();
+ drw = drw_create(dpy, screen, root, wa.width, wa.height, visual, depth, cmap);
if (!drw_fontset_create(drw, fonts, LENGTH(fonts)))
die("no fonts could be loaded.");
lrpad = drw->fonts->h;
@@ -769,3 +782,40 @@ main(int argc, char *argv[])
return 1; /* unreachable */
}
+
+ void
+xinitvisual()
+{
+ XVisualInfo *infos;
+ XRenderPictFormat *fmt;
+ int nitems;
+ int i;
+
+ XVisualInfo tpl = {
+ .screen = screen,
+ .depth = 32,
+ .class = TrueColor
+ };
+ long masks = VisualScreenMask | VisualDepthMask | VisualClassMask;
+
+ infos = XGetVisualInfo(dpy, masks, &tpl, &nitems);
+ visual = NULL;
+ for(i = 0; i < nitems; i ++) {
+ fmt = XRenderFindVisualFormat(dpy, infos[i].visual);
+ if (fmt->type == PictTypeDirect && fmt->direct.alphaMask) {
+ visual = infos[i].visual;
+ depth = infos[i].depth;
+ cmap = XCreateColormap(dpy, root, visual, AllocNone);
+ useargb = 1;
+ break;
+ }
+ }
+
+ XFree(infos);
+
+ if (! visual) {
+ visual = DefaultVisual(dpy, screen);
+ depth = DefaultDepth(dpy, screen);
+ cmap = DefaultColormap(dpy, screen);
+ }
+}
diff --git a/drw.c b/drw.c
index 4cdbcbe..fe3aadd 100644
--- a/drw.c
+++ b/drw.c
@@ -61,7 +61,7 @@ utf8decode(const char *c, long *u, size_t clen)
}
Drw *
-drw_create(Display *dpy, int screen, Window root, unsigned int w, unsigned int h)
+drw_create(Display *dpy, int screen, Window root, unsigned int w, unsigned int h, Visual *visual, unsigned int depth, Colormap cmap)
{
Drw *drw = ecalloc(1, sizeof(Drw));
@@ -70,8 +70,11 @@ drw_create(Display *dpy, int screen, Window root, unsigned int w, unsigned int h
drw->root = root;
drw->w = w;
drw->h = h;
- drw->drawable = XCreatePixmap(dpy, root, w, h, DefaultDepth(dpy, screen));
- drw->gc = XCreateGC(dpy, root, 0, NULL);
+ drw->visual = visual;
+ drw->depth = depth;
+ drw->cmap = cmap;
+ drw->drawable = XCreatePixmap(dpy, root, w, h, depth);
+ drw->gc = XCreateGC(dpy, drw->drawable, 0, NULL);
XSetLineAttributes(dpy, drw->gc, 1, LineSolid, CapButt, JoinMiter);
return drw;
@@ -87,7 +90,7 @@ drw_resize(Drw *drw, unsigned int w, unsigned int h)
drw->h = h;
if (drw->drawable)
XFreePixmap(drw->dpy, drw->drawable);
- drw->drawable = XCreatePixmap(drw->dpy, drw->root, w, h, DefaultDepth(drw->dpy, drw->screen));
+ drw->drawable = XCreatePixmap(drw->dpy, drw->root, w, h, drw->depth);
}
void
@@ -194,21 +197,22 @@ drw_fontset_free(Fnt *font)
}
void
-drw_clr_create(Drw *drw, Clr *dest, const char *clrname)
+drw_clr_create(Drw *drw, Clr *dest, const char *clrname, unsigned int alpha)
{
if (!drw || !dest || !clrname)
return;
- if (!XftColorAllocName(drw->dpy, DefaultVisual(drw->dpy, drw->screen),
- DefaultColormap(drw->dpy, drw->screen),
+ if (!XftColorAllocName(drw->dpy, drw->visual, drw->cmap,
clrname, dest))
die("error, cannot allocate color '%s'", clrname);
+
+ dest->pixel = (dest->pixel & 0x00ffffffU) | (alpha << 24);
}
/* Wrapper to create color schemes. The caller has to call free(3) on the
* returned color scheme when done using it. */
Clr *
-drw_scm_create(Drw *drw, const char *clrnames[], size_t clrcount)
+drw_scm_create(Drw *drw, const char *clrnames[], const unsigned int alphas[], size_t clrcount)
{
size_t i;
Clr *ret;
@@ -218,7 +222,7 @@ drw_scm_create(Drw *drw, const char *clrnames[], size_t clrcount)
return NULL;
for (i = 0; i < clrcount; i++)
- drw_clr_create(drw, &ret[i], clrnames[i]);
+ drw_clr_create(drw, &ret[i], clrnames[i], alphas[i]);
return ret;
}
@@ -274,9 +278,7 @@ drw_text(Drw *drw, int x, int y, unsigned int w, unsigned int h, unsigned int lp
} else {
XSetForeground(drw->dpy, drw->gc, drw->scheme[invert ? ColFg : ColBg].pixel);
XFillRectangle(drw->dpy, drw->drawable, drw->gc, x, y, w, h);
- d = XftDrawCreate(drw->dpy, drw->drawable,
- DefaultVisual(drw->dpy, drw->screen),
- DefaultColormap(drw->dpy, drw->screen));
+ d = XftDrawCreate(drw->dpy, drw->drawable, drw->visual, drw->cmap);
x += lpad;
w -= lpad;
}
diff --git a/drw.h b/drw.h
index 4c67419..f6fa5cd 100644
--- a/drw.h
+++ b/drw.h
@@ -20,6 +20,9 @@ typedef struct {
Display *dpy;
int screen;
Window root;
+ Visual *visual;
+ unsigned int depth;
+ Colormap cmap;
Drawable drawable;
GC gc;
Clr *scheme;
@@ -27,7 +30,7 @@ typedef struct {
} Drw;
/* Drawable abstraction */
-Drw *drw_create(Display *dpy, int screen, Window win, unsigned int w, unsigned int h);
+Drw *drw_create(Display *dpy, int screen, Window win, unsigned int w, unsigned int h, Visual*, unsigned int, Colormap);
void drw_resize(Drw *drw, unsigned int w, unsigned int h);
void drw_free(Drw *drw);
@@ -38,8 +41,8 @@ unsigned int drw_fontset_getwidth(Drw *drw, const char *text);
void drw_font_getexts(Fnt *font, const char *text, unsigned int len, unsigned int *w, unsigned int *h);
/* Colorscheme abstraction */
-void drw_clr_create(Drw *drw, Clr *dest, const char *clrname);
-Clr *drw_scm_create(Drw *drw, const char *clrnames[], size_t clrcount);
+void drw_clr_create(Drw *drw, Clr *dest, const char *clrname, unsigned int alpha);
+Clr *drw_scm_create(Drw *drw, const char *clrnames[], const unsigned int alphas[], size_t clrcount);
/* Cursor abstraction */
Cur *drw_cur_create(Drw *drw, int shape);

@ -0,0 +1,267 @@
diff --git a/config.def.h b/config.def.h
index 1edb647..697d511 100644
--- a/config.def.h
+++ b/config.def.h
@@ -2,6 +2,7 @@
/* Default settings; can be overriden by command line. */
static int topbar = 1; /* -b option; if 0, dmenu appears at bottom */
+static const unsigned int alpha = 0xf0;
/* -fn option overrides fonts[0]; default X11 font or font set */
static const char *fonts[] = {
"monospace:size=10"
@@ -13,6 +14,13 @@ static const char *colors[SchemeLast][2] = {
[SchemeSel] = { "#eeeeee", "#005577" },
[SchemeOut] = { "#000000", "#00ffff" },
};
+
+static const unsigned int alphas[SchemeLast][2] = {
+ [SchemeNorm] = { OPAQUE, alpha },
+ [SchemeSel] = { OPAQUE, alpha },
+ [SchemeOut] = { OPAQUE, alpha },
+};
+
/* -l option; if nonzero, dmenu uses vertical list with given number of lines */
static unsigned int lines = 0;
diff --git a/dmenu.c b/dmenu.c
index 65f25ce..3e56e1a 100644
--- a/dmenu.c
+++ b/dmenu.c
@@ -10,6 +10,7 @@
#include <X11/Xlib.h>
#include <X11/Xatom.h>
+#include <X11/Xproto.h>
#include <X11/Xutil.h>
#ifdef XINERAMA
#include <X11/extensions/Xinerama.h>
@@ -25,6 +26,8 @@
#define LENGTH(X) (sizeof X / sizeof X[0])
#define TEXTW(X) (drw_fontset_getwidth(drw, (X)) + lrpad)
+#define OPAQUE 0xffU
+
/* enums */
enum { SchemeNorm, SchemeSel, SchemeOut, SchemeLast }; /* color schemes */
@@ -53,10 +56,16 @@ static XIC xic;
static Drw *drw;
static Clr *scheme[SchemeLast];
+static int useargb = 0;
+static Visual *visual;
+static int depth;
+static Colormap cmap;
+
#include "config.h"
static int (*fstrncmp)(const char *, const char *, size_t) = strncmp;
static char *(*fstrstr)(const char *, const char *) = strstr;
+static void xinitvisual();
static void
appenditem(struct item *item, struct item **list, struct item **last)
@@ -602,7 +611,7 @@ setup(void)
#endif
/* init appearance */
for (j = 0; j < SchemeLast; j++)
- scheme[j] = drw_scm_create(drw, colors[j], 2);
+ scheme[j] = drw_scm_create(drw, colors[j], alphas[i], 2);
clip = XInternAtom(dpy, "CLIPBOARD", False);
utf8 = XInternAtom(dpy, "UTF8_STRING", False);
@@ -640,6 +649,7 @@ setup(void)
x = info[i].x_org;
y = info[i].y_org + (topbar ? 0 : info[i].height - mh);
mw = info[i].width;
+
XFree(info);
} else
#endif
@@ -657,11 +667,13 @@ setup(void)
/* create menu window */
swa.override_redirect = True;
- swa.background_pixel = scheme[SchemeNorm][ColBg].pixel;
+ swa.background_pixel = 0;
+ swa.border_pixel = 0;
+ swa.colormap = cmap;
swa.event_mask = ExposureMask | KeyPressMask | VisibilityChangeMask;
- win = XCreateWindow(dpy, parentwin, x, y, mw, mh, 0,
- CopyFromParent, CopyFromParent, CopyFromParent,
- CWOverrideRedirect | CWBackPixel | CWEventMask, &swa);
+ win = XCreateWindow(dpy, parentwin, x, y, mw, mh, border_width,
+ depth, CopyFromParent, visual,
+ CWOverrideRedirect | CWBackPixel | CWBorderPixel | CWColormap | CWEventMask, &swa);
XSetClassHint(dpy, win, &ch);
@@ -747,7 +759,8 @@ main(int argc, char *argv[])
if (!XGetWindowAttributes(dpy, parentwin, &wa))
die("could not get embedding window attributes: 0x%lx",
parentwin);
- drw = drw_create(dpy, screen, root, wa.width, wa.height);
+ xinitvisual();
+ drw = drw_create(dpy, screen, root, wa.width, wa.height, visual, depth, cmap);
if (!drw_fontset_create(drw, fonts, LENGTH(fonts)))
die("no fonts could be loaded.");
lrpad = drw->fonts->h;
@@ -769,3 +782,40 @@ main(int argc, char *argv[])
return 1; /* unreachable */
}
+
+ void
+xinitvisual()
+{
+ XVisualInfo *infos;
+ XRenderPictFormat *fmt;
+ int nitems;
+ int i;
+
+ XVisualInfo tpl = {
+ .screen = screen,
+ .depth = 32,
+ .class = TrueColor
+ };
+ long masks = VisualScreenMask | VisualDepthMask | VisualClassMask;
+
+ infos = XGetVisualInfo(dpy, masks, &tpl, &nitems);
+ visual = NULL;
+ for(i = 0; i < nitems; i ++) {
+ fmt = XRenderFindVisualFormat(dpy, infos[i].visual);
+ if (fmt->type == PictTypeDirect && fmt->direct.alphaMask) {
+ visual = infos[i].visual;
+ depth = infos[i].depth;
+ cmap = XCreateColormap(dpy, root, visual, AllocNone);
+ useargb = 1;
+ break;
+ }
+ }
+
+ XFree(infos);
+
+ if (! visual) {
+ visual = DefaultVisual(dpy, screen);
+ depth = DefaultDepth(dpy, screen);
+ cmap = DefaultColormap(dpy, screen);
+ }
+}
diff --git a/drw.c b/drw.c
index 4cdbcbe..fe3aadd 100644
--- a/drw.c
+++ b/drw.c
@@ -61,7 +61,7 @@ utf8decode(const char *c, long *u, size_t clen)
}
Drw *
-drw_create(Display *dpy, int screen, Window root, unsigned int w, unsigned int h)
+drw_create(Display *dpy, int screen, Window root, unsigned int w, unsigned int h, Visual *visual, unsigned int depth, Colormap cmap)
{
Drw *drw = ecalloc(1, sizeof(Drw));
@@ -70,8 +70,11 @@ drw_create(Display *dpy, int screen, Window root, unsigned int w, unsigned int h
drw->root = root;
drw->w = w;
drw->h = h;
- drw->drawable = XCreatePixmap(dpy, root, w, h, DefaultDepth(dpy, screen));
- drw->gc = XCreateGC(dpy, root, 0, NULL);
+ drw->visual = visual;
+ drw->depth = depth;
+ drw->cmap = cmap;
+ drw->drawable = XCreatePixmap(dpy, root, w, h, depth);
+ drw->gc = XCreateGC(dpy, drw->drawable, 0, NULL);
XSetLineAttributes(dpy, drw->gc, 1, LineSolid, CapButt, JoinMiter);
return drw;
@@ -87,7 +90,7 @@ drw_resize(Drw *drw, unsigned int w, unsigned int h)
drw->h = h;
if (drw->drawable)
XFreePixmap(drw->dpy, drw->drawable);
- drw->drawable = XCreatePixmap(drw->dpy, drw->root, w, h, DefaultDepth(drw->dpy, drw->screen));
+ drw->drawable = XCreatePixmap(drw->dpy, drw->root, w, h, drw->depth);
}
void
@@ -194,21 +197,22 @@ drw_fontset_free(Fnt *font)
}
void
-drw_clr_create(Drw *drw, Clr *dest, const char *clrname)
+drw_clr_create(Drw *drw, Clr *dest, const char *clrname, unsigned int alpha)
{
if (!drw || !dest || !clrname)
return;
- if (!XftColorAllocName(drw->dpy, DefaultVisual(drw->dpy, drw->screen),
- DefaultColormap(drw->dpy, drw->screen),
+ if (!XftColorAllocName(drw->dpy, drw->visual, drw->cmap,
clrname, dest))
die("error, cannot allocate color '%s'", clrname);
+
+ dest->pixel = (dest->pixel & 0x00ffffffU) | (alpha << 24);
}
/* Wrapper to create color schemes. The caller has to call free(3) on the
* returned color scheme when done using it. */
Clr *
-drw_scm_create(Drw *drw, const char *clrnames[], size_t clrcount)
+drw_scm_create(Drw *drw, const char *clrnames[], const unsigned int alphas[], size_t clrcount)
{
size_t i;
Clr *ret;
@@ -218,7 +222,7 @@ drw_scm_create(Drw *drw, const char *clrnames[], size_t clrcount)
return NULL;
for (i = 0; i < clrcount; i++)
- drw_clr_create(drw, &ret[i], clrnames[i]);
+ drw_clr_create(drw, &ret[i], clrnames[i], alphas[i]);
return ret;
}
@@ -274,9 +278,7 @@ drw_text(Drw *drw, int x, int y, unsigned int w, unsigned int h, unsigned int lp
} else {
XSetForeground(drw->dpy, drw->gc, drw->scheme[invert ? ColFg : ColBg].pixel);
XFillRectangle(drw->dpy, drw->drawable, drw->gc, x, y, w, h);
- d = XftDrawCreate(drw->dpy, drw->drawable,
- DefaultVisual(drw->dpy, drw->screen),
- DefaultColormap(drw->dpy, drw->screen));
+ d = XftDrawCreate(drw->dpy, drw->drawable, drw->visual, drw->cmap);
x += lpad;
w -= lpad;
}
diff --git a/drw.h b/drw.h
index 4c67419..f6fa5cd 100644
--- a/drw.h
+++ b/drw.h
@@ -20,6 +20,9 @@ typedef struct {
Display *dpy;
int screen;
Window root;
+ Visual *visual;
+ unsigned int depth;
+ Colormap cmap;
Drawable drawable;
GC gc;
Clr *scheme;
@@ -27,7 +30,7 @@ typedef struct {
} Drw;
/* Drawable abstraction */
-Drw *drw_create(Display *dpy, int screen, Window win, unsigned int w, unsigned int h);
+Drw *drw_create(Display *dpy, int screen, Window win, unsigned int w, unsigned int h, Visual*, unsigned int, Colormap);
void drw_resize(Drw *drw, unsigned int w, unsigned int h);
void drw_free(Drw *drw);
@@ -38,8 +41,8 @@ unsigned int drw_fontset_getwidth(Drw *drw, const char *text);
void drw_font_getexts(Fnt *font, const char *text, unsigned int len, unsigned int *w, unsigned int *h);
/* Colorscheme abstraction */
-void drw_clr_create(Drw *drw, Clr *dest, const char *clrname);
-Clr *drw_scm_create(Drw *drw, const char *clrnames[], size_t clrcount);
+void drw_clr_create(Drw *drw, Clr *dest, const char *clrname, unsigned int alpha);
+Clr *drw_scm_create(Drw *drw, const char *clrnames[], const unsigned int alphas[], size_t clrcount);
/* Cursor abstraction */
Cur *drw_cur_create(Drw *drw, int shape);

@ -0,0 +1,25 @@
diff -up dmenu-4.9-b/config.def.h dmenu-4.9-a/config.def.h
--- dmenu-4.9-b/config.def.h 2019-02-02 13:55:02.000000000 +0100
+++ dmenu-4.9-a/config.def.h 2019-05-19 02:10:12.740040403 +0200
@@ -21,3 +21,6 @@ static unsigned int lines = 0;
* for example: " /?\"&[]"
*/
static const char worddelimiters[] = " ";
+
+/* Size of the window border */
+static const unsigned int border_width = 5;
diff -up dmenu-4.9-b/dmenu.c dmenu-4.9-a/dmenu.c
--- dmenu-4.9-b/dmenu.c 2019-02-02 13:55:02.000000000 +0100
+++ dmenu-4.9-a/dmenu.c 2019-05-19 02:11:20.966710117 +0200
@@ -654,9 +654,10 @@ setup(void)
swa.override_redirect = True;
swa.background_pixel = scheme[SchemeNorm][ColBg].pixel;
swa.event_mask = ExposureMask | KeyPressMask | VisibilityChangeMask;
- win = XCreateWindow(dpy, parentwin, x, y, mw, mh, 0,
+ win = XCreateWindow(dpy, parentwin, x, y, mw, mh, border_width,
CopyFromParent, CopyFromParent, CopyFromParent,
CWOverrideRedirect | CWBackPixel | CWEventMask, &swa);
+ XSetWindowBorder(dpy, win, scheme[SchemeSel][ColBg].pixel);
XSetClassHint(dpy, win, &ch);
/* open input methods */

@ -0,0 +1,104 @@
diff --git a/config.def.h b/config.def.h
index 1edb647..88ef264 100644
--- a/config.def.h
+++ b/config.def.h
@@ -2,6 +2,8 @@
/* Default settings; can be overriden by command line. */
static int topbar = 1; /* -b option; if 0, dmenu appears at bottom */
+static int centered = 0; /* -c option; centers dmenu on screen */
+static int min_width = 500; /* minimum width when centered */
/* -fn option overrides fonts[0]; default X11 font or font set */
static const char *fonts[] = {
"monospace:size=10"
diff --git a/dmenu.1 b/dmenu.1
index 323f93c..c036baa 100644
--- a/dmenu.1
+++ b/dmenu.1
@@ -40,6 +40,9 @@ which lists programs in the user's $PATH and runs the result in their $SHELL.
.B \-b
dmenu appears at the bottom of the screen.
.TP
+.B \-c
+dmenu appears centered on the screen.
+.TP
.B \-f
dmenu grabs the keyboard before reading stdin if not reading from a tty. This
is faster, but will lock up X until stdin reaches end\-of\-file.
diff --git a/dmenu.c b/dmenu.c
index 27b7a30..427fb04 100644
--- a/dmenu.c
+++ b/dmenu.c
@@ -96,6 +96,15 @@ calcoffsets(void)
break;
}
+static int
+max_textw(void)
+{
+ int len = 0;
+ for (struct item *item = items; item && item->text; item++)
+ len = MAX(TEXTW(item->text), len);
+ return len;
+}
+
static void
cleanup(void)
{
@@ -636,6 +645,7 @@ setup(void)
bh = drw->fonts->h + 2;
lines = MAX(lines, 0);
mh = (lines + 1) * bh;
+ promptw = (prompt && *prompt) ? TEXTW(prompt) - lrpad / 4 : 0;
#ifdef XINERAMA
i = 0;
if (parentwin == root && (info = XineramaQueryScreens(dpy, &n))) {
@@ -662,9 +672,16 @@ setup(void)
if (INTERSECT(x, y, 1, 1, info[i]) != 0)
break;
- x = info[i].x_org;
- y = info[i].y_org + (topbar ? 0 : info[i].height - mh);
- mw = info[i].width;
+ if (centered) {
+ mw = MIN(MAX(max_textw() + promptw, min_width), info[i].width);
+ x = info[i].x_org + ((info[i].width - mw) / 2);
+ y = info[i].y_org + ((info[i].height - mh) / 2);
+ } else {
+ x = info[i].x_org;
+ y = info[i].y_org + (topbar ? 0 : info[i].height - mh);
+ mw = info[i].width;
+ }
+
XFree(info);
} else
#endif
@@ -672,9 +689,16 @@ setup(void)
if (!XGetWindowAttributes(dpy, parentwin, &wa))
die("could not get embedding window attributes: 0x%lx",
parentwin);
- x = 0;
- y = topbar ? 0 : wa.height - mh;
- mw = wa.width;
+
+ if (centered) {
+ mw = MIN(MAX(max_textw() + promptw, min_width), wa.width);
+ x = (wa.width - mw) / 2;
+ y = (wa.height - mh) / 2;
+ } else {
+ x = 0;
+ y = topbar ? 0 : wa.height - mh;
+ mw = wa.width;
+ }
}
promptw = (prompt && *prompt) ? TEXTW(prompt) - lrpad / 4 : 0;
inputw = mw / 3; /* input width: ~33% of monitor width */
@@ -733,6 +757,8 @@ main(int argc, char *argv[])
topbar = 0;
else if (!strcmp(argv[i], "-f")) /* grabs keyboard before reading stdin */
fast = 1;
+ else if (!strcmp(argv[i], "-c")) /* centers dmenu on screen */
+ centered = 1;
else if (!strcmp(argv[i], "-i")) { /* case-insensitive item matching */
fstrncmp = strncasecmp;
fstrstr = cistrstr;

@ -0,0 +1,27 @@
From f16313b64965d74e6cbb30fa41d53aaf09b9ad49 Mon Sep 17 00:00:00 2001
From: David Lima <antdavidlima@gmail.com>
Date: Sun, 28 Nov 2021 17:02:43 -0300
Subject: [PATCH] apply dracula theme to dmenu
---
config.def.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/config.def.h b/config.def.h
index 1edb647..e688388 100644
--- a/config.def.h
+++ b/config.def.h
@@ -9,8 +9,8 @@ static const char *fonts[] = {
static const char *prompt = NULL; /* -p option; prompt to the left of input field */
static const char *colors[SchemeLast][2] = {
/* fg bg */
- [SchemeNorm] = { "#bbbbbb", "#222222" },
- [SchemeSel] = { "#eeeeee", "#005577" },
+ [SchemeNorm] = { "#f8f8f2", "#282a36" },
+ [SchemeSel] = { "#f8f8f2", "#6272a4" },
[SchemeOut] = { "#000000", "#00ffff" },
};
/* -l option; if nonzero, dmenu uses vertical list with given number of lines */
--
2.34.1

@ -0,0 +1,94 @@
From a06d0d3d7bbb3c0f5bad44934dbbf1e88e7d9558 Mon Sep 17 00:00:00 2001
From: Miles Alan <m@milesalan.com>
Date: Sat, 4 Jul 2020 11:49:04 -0500
Subject: [PATCH] Highlight matched text in a different color scheme
---
config.def.h | 2 ++
dmenu.c | 43 +++++++++++++++++++++++++++++++++++++++++--
2 files changed, 43 insertions(+), 2 deletions(-)
diff --git a/config.def.h b/config.def.h
index 1edb647..64eab2a 100644
--- a/config.def.h
+++ b/config.def.h
@@ -11,6 +11,8 @@ static const char *colors[SchemeLast][2] = {
/* fg bg */
[SchemeNorm] = { "#bbbbbb", "#222222" },
[SchemeSel] = { "#eeeeee", "#005577" },
+ [SchemeSelHighlight] = { "#ffc978", "#005577" },
+ [SchemeNormHighlight] = { "#ffc978", "#222222" },
[SchemeOut] = { "#000000", "#00ffff" },
};
/* -l option; if nonzero, dmenu uses vertical list with given number of lines */
diff --git a/dmenu.c b/dmenu.c
index 6b8f51b..d5e1991 100644
--- a/dmenu.c
+++ b/dmenu.c
@@ -26,7 +26,7 @@
#define TEXTW(X) (drw_fontset_getwidth(drw, (X)) + lrpad)
/* enums */
-enum { SchemeNorm, SchemeSel, SchemeOut, SchemeLast }; /* color schemes */
+enum { SchemeNorm, SchemeSel, SchemeOut, SchemeNormHighlight, SchemeSelHighlight, SchemeLast }; /* color schemes */
struct item {
char *text;
@@ -113,6 +113,43 @@ cistrstr(const char *s, const char *sub)
return NULL;
}
+static void
+drawhighlights(struct item *item, int x, int y, int maxw)
+{
+ char restorechar, tokens[sizeof text], *highlight, *token;
+ int indentx, highlightlen;
+
+ drw_setscheme(drw, scheme[item == sel ? SchemeSelHighlight : SchemeNormHighlight]);
+ strcpy(tokens, text);
+ for (token = strtok(tokens, " "); token; token = strtok(NULL, " ")) {
+ highlight = fstrstr(item->text, token);
+ while (highlight) {
+ // Move item str end, calc width for highlight indent, & restore
+ highlightlen = highlight - item->text;
+ restorechar = *highlight;
+ item->text[highlightlen] = '\0';
+ indentx = TEXTW(item->text);
+ item->text[highlightlen] = restorechar;
+
+ // Move highlight str end, draw highlight, & restore
+ restorechar = highlight[strlen(token)];
+ highlight[strlen(token)] = '\0';
+ if (indentx - (lrpad / 2) - 1 < maxw)
+ drw_text(
+ drw,
+ x + indentx - (lrpad / 2) - 1,
+ y,
+ MIN(maxw - indentx, TEXTW(highlight) - lrpad),
+ bh, 0, highlight, 0
+ );
+ highlight[strlen(token)] = restorechar;
+
+ if (strlen(highlight) - strlen(token) < strlen(token)) break;
+ highlight = fstrstr(highlight + strlen(token), token);
+ }
+ }
+}
+
static int
drawitem(struct item *item, int x, int y, int w)
{
@@ -123,7 +160,9 @@ drawitem(struct item *item, int x, int y, int w)
else
drw_setscheme(drw, scheme[SchemeNorm]);
- return drw_text(drw, x, y, w, bh, lrpad / 2, item->text, 0);
+ int r = drw_text(drw, x, y, w, bh, lrpad / 2, item->text, 0);
+ drawhighlights(item, x, y, w);
+ return r;
}
static void
--
2.23.1

@ -0,0 +1,106 @@
From ba103e38ea4ab07f9a3ee90627714b9bea17c329 Mon Sep 17 00:00:00 2001
From: pskry <peter@skrypalle.dk>
Date: Sun, 8 Nov 2020 22:04:22 +0100
Subject: [PATCH] Add an option which defines the lineheight
Despite both the panel and dmenu using the same font (a Terminus 12),
dmenu is shorter and the panel is visible from under the dmenu bar.
The appearance can be even more distracting when using similar colors
for background and selections. With the option added by this patch,
dmenu can be launched with a '-h 24', thus completely covering the panel.
---
config.def.h | 3 +++
dmenu.1 | 5 +++++
dmenu.c | 11 ++++++++---
3 files changed, 16 insertions(+), 3 deletions(-)
diff --git a/config.def.h b/config.def.h
index 1edb647..4394dec 100644
--- a/config.def.h
+++ b/config.def.h
@@ -15,6 +15,9 @@ static const char *colors[SchemeLast][2] = {
};
/* -l option; if nonzero, dmenu uses vertical list with given number of lines */
static unsigned int lines = 0;
+/* -h option; minimum height of a menu line */
+static unsigned int lineheight = 0;
+static unsigned int min_lineheight = 8;
/*
* Characters not considered part of a word while deleting words
diff --git a/dmenu.1 b/dmenu.1
index 323f93c..f2a82b4 100644
--- a/dmenu.1
+++ b/dmenu.1
@@ -6,6 +6,8 @@ dmenu \- dynamic menu
.RB [ \-bfiv ]
.RB [ \-l
.IR lines ]
+.RB [ \-h
+.IR height ]
.RB [ \-m
.IR monitor ]
.RB [ \-p
@@ -50,6 +52,9 @@ dmenu matches menu items case insensitively.
.BI \-l " lines"
dmenu lists items vertically, with the given number of lines.
.TP
+.BI \-h " height"
+dmenu uses a menu line of at least 'height' pixels tall, but no less than 8.
+.TP
.BI \-m " monitor"
dmenu is displayed on the monitor number supplied. Monitor numbers are starting
from 0.
diff --git a/dmenu.c b/dmenu.c
index e7be8af..82b204b 100644
--- a/dmenu.c
+++ b/dmenu.c
@@ -148,7 +148,7 @@ drawmenu(void)
{
unsigned int curpos;
struct item *item;
- int x = 0, y = 0, w;
+ int x = 0, y = 0, fh = drw->fonts->h, w;
drw_setscheme(drw, scheme[SchemeNorm]);
drw_rect(drw, 0, 0, mw, mh, 1, 1);
@@ -165,7 +165,7 @@ drawmenu(void)
curpos = TEXTW(text) - TEXTW(&text[cursor]);
if ((curpos += lrpad / 2 - 1) < w) {
drw_setscheme(drw, scheme[SchemeNorm]);
- drw_rect(drw, x + curpos, 2, 2, bh - 4, 1, 0);
+ drw_rect(drw, x + curpos, 2 + (bh - fh) / 2, 2, fh - 4, 1, 0);
}
if (lines > 0) {
@@ -630,6 +630,7 @@ setup(void)
/* calculate menu geometry */
bh = drw->fonts->h + 2;
+ bh = MAX(bh,lineheight); /* make a menu line AT LEAST 'lineheight' tall */
lines = MAX(lines, 0);
mh = (lines + 1) * bh;
#ifdef XINERAMA
@@ -710,7 +711,7 @@ setup(void)
static void
usage(void)
{
- die("usage: dmenu [-bfiv] [-l lines] [-p prompt] [-fn font] [-m monitor]\n"
+ die("usage: dmenu [-bfiv] [-l lines] [-h height] [-p prompt] [-fn font] [-m monitor]\n"
" [-nb color] [-nf color] [-sb color] [-sf color] [-w windowid]");
}
@@ -737,6 +738,10 @@ main(int argc, char *argv[])
/* these options take one argument */
else if (!strcmp(argv[i], "-l")) /* number of lines in vertical list */
lines = atoi(argv[++i]);
+ else if (!strcmp(argv[i], "-h")) { /* minimum height of one menu line */
+ lineheight = atoi(argv[++i]);
+ lineheight = MAX(lineheight, min_lineheight);
+ }
else if (!strcmp(argv[i], "-m"))
mon = atoi(argv[++i]);
else if (!strcmp(argv[i], "-p")) /* adds prompt to left of input field */
--
2.38.1

@ -0,0 +1,89 @@
From c4cd209c2e322563750d09a3b64194d11cc12a10 Mon Sep 17 00:00:00 2001
From: Ehsan Ghorbannezhad <ehsan@disroot.org>
Date: Thu, 12 May 2022 22:32:47 +0430
Subject: [PATCH] the numbers patch, updated to fix segfault in some conditions
---
dmenu.c | 27 ++++++++++++++++++++++++---
1 file changed, 24 insertions(+), 3 deletions(-)
diff --git a/dmenu.c b/dmenu.c
index 571bc35..70004e7 100644
--- a/dmenu.c
+++ b/dmenu.c
@@ -24,6 +24,8 @@
* MAX(0, MIN((y)+(h),(r).y_org+(r).height) - MAX((y),(r).y_org)))
#define LENGTH(X) (sizeof X / sizeof X[0])
#define TEXTW(X) (drw_fontset_getwidth(drw, (X)) + lrpad)
+#define NUMBERSMAXDIGITS 100
+#define NUMBERSBUFSIZE (NUMBERSMAXDIGITS * 2) + 1
/* enums */
enum { SchemeNorm, SchemeSel, SchemeOut, SchemeLast }; /* color schemes */
@@ -34,6 +36,7 @@ struct item {
int out;
};
+static char numbers[NUMBERSBUFSIZE] = "";
static char text[BUFSIZ] = "";
static char *embed;
static int bh, mw, mh;
@@ -86,7 +89,7 @@ calcoffsets(void)
if (lines > 0)
n = lines * bh;
else
- n = mw - (promptw + inputw + TEXTW("<") + TEXTW(">"));
+ n = mw - (promptw + inputw + TEXTW("<") + TEXTW(">") + TEXTW(numbers));
/* calculate which items will begin the next page and previous page */
for (i = 0, next = curr; next; next = next->right)
if ((i += (lines > 0) ? bh : textw_clamp(next->text, n)) > n)
@@ -143,6 +146,21 @@ drawitem(struct item *item, int x, int y, int w)
return drw_text(drw, x, y, w, bh, lrpad / 2, item->text, 0);
}
+static void
+recalculatenumbers()
+{
+ unsigned int numer = 0, denom = 0;
+ struct item *item;
+ if (matchend) {
+ numer++;
+ for (item = matchend; item && item->left; item = item->left)
+ numer++;
+ }
+ for (item = items; item && item->text; item++)
+ denom++;
+ snprintf(numbers, NUMBERSBUFSIZE, "%d/%d", numer, denom);
+}
+
static void
drawmenu(void)
{
@@ -168,6 +186,7 @@ drawmenu(void)
drw_rect(drw, x + curpos, 2, 2, bh - 4, 1, 0);
}
+ recalculatenumbers();
if (lines > 0) {
/* draw vertical list */
for (item = curr; item != next; item = item->right)
@@ -182,13 +201,15 @@ drawmenu(void)
}
x += w;
for (item = curr; item != next; item = item->right)
- x = drawitem(item, x, 0, textw_clamp(item->text, mw - x - TEXTW(">")));
+ x = drawitem(item, x, 0, textw_clamp(item->text, mw - x - TEXTW(">") - TEXTW(numbers)));
if (next) {
w = TEXTW(">");
drw_setscheme(drw, scheme[SchemeNorm]);
- drw_text(drw, mw - w, 0, w, bh, lrpad / 2, ">", 0);
+ drw_text(drw, mw - w - TEXTW(numbers), 0, w, bh, lrpad / 2, ">", 0);
}
}
+ drw_setscheme(drw, scheme[SchemeNorm]);
+ drw_text(drw, mw - TEXTW(numbers), 0, TEXTW(numbers), bh, lrpad / 2, numbers, 0);
drw_map(drw, win, 0, 0, mw, mh);
}
--
2.36.1

@ -0,0 +1,202 @@
.TH DMENU 1 dmenu\-VERSION
.SH NAME
dmenu \- dynamic menu
.SH SYNOPSIS
.B dmenu
.RB [ \-bfiv ]
.RB [ \-l
.IR lines ]
.RB [ \-h
.IR height ]
.RB [ \-m
.IR monitor ]
.RB [ \-p
.IR prompt ]
.RB [ \-fn
.IR font ]
.RB [ \-nb
.IR color ]
.RB [ \-nf
.IR color ]
.RB [ \-sb
.IR color ]
.RB [ \-sf
.IR color ]
.RB [ \-w
.IR windowid ]
.P
.BR dmenu_run " ..."
.SH DESCRIPTION
.B dmenu
is a dynamic menu for X, which reads a list of newline\-separated items from
stdin. When the user selects an item and presses Return, their choice is printed
to stdout and dmenu terminates. Entering text will narrow the items to those
matching the tokens in the input.
.P
.B dmenu_run
is a script used by
.IR dwm (1)
which lists programs in the user's $PATH and runs the result in their $SHELL.
.SH OPTIONS
.TP
.B \-b
dmenu appears at the bottom of the screen.
.TP
.B \-c
dmenu appears centered on the screen.
.TP
.B \-f
dmenu grabs the keyboard before reading stdin if not reading from a tty. This
is faster, but will lock up X until stdin reaches end\-of\-file.
.TP
.B \-i
dmenu matches menu items case insensitively.
.TP
.BI \-l " lines"
dmenu lists items vertically, with the given number of lines.
.TP
.BI \-h " height"
dmenu uses a menu line of at least 'height' pixels tall, but no less than 8.
.TP
.BI \-m " monitor"
dmenu is displayed on the monitor number supplied. Monitor numbers are starting
from 0.
.TP
.BI \-p " prompt"
defines the prompt to be displayed to the left of the input field.
.TP
.BI \-fn " font"
defines the font or font set used.
.TP
.BI \-nb " color"
defines the normal background color.
.IR #RGB ,
.IR #RRGGBB ,
and X color names are supported.
.TP
.BI \-nf " color"
defines the normal foreground color.
.TP
.BI \-sb " color"
defines the selected background color.
.TP
.BI \-sf " color"
defines the selected foreground color.
.TP
.B \-v
prints version information to stdout, then exits.
.TP
.BI \-w " windowid"
embed into windowid.
.SH USAGE
dmenu is completely controlled by the keyboard. Items are selected using the
arrow keys, page up, page down, home, and end.
.TP
.B Tab
Copy the selected item to the input field.
.TP
.B Return
Confirm selection. Prints the selected item to stdout and exits, returning
success.
.TP
.B Ctrl-Return
Confirm selection. Prints the selected item to stdout and continues.
.TP
.B Shift\-Return
Confirm input. Prints the input text to stdout and exits, returning success.
.TP
.B Escape
Exit without selecting an item, returning failure.
.TP
.B Ctrl-Left
Move cursor to the start of the current word
.TP
.B Ctrl-Right
Move cursor to the end of the current word
.TP
.B C\-a
Home
.TP
.B C\-b
Left
.TP
.B C\-c
Escape
.TP
.B C\-d
Delete
.TP
.B C\-e
End
.TP
.B C\-f
Right
.TP
.B C\-g
Escape
.TP
.B C\-h
Backspace
.TP
.B C\-i
Tab
.TP
.B C\-j
Return
.TP
.B C\-J
Shift-Return
.TP
.B C\-k
Delete line right
.TP
.B C\-m
Return
.TP
.B C\-M
Shift-Return
.TP
.B C\-n
Down
.TP
.B C\-p
Up
.TP
.B C\-u
Delete line left
.TP
.B C\-w
Delete word left
.TP
.B C\-y
Paste from primary X selection
.TP
.B C\-Y
Paste from X clipboard
.TP
.B M\-b
Move cursor to the start of the current word
.TP
.B M\-f
Move cursor to the end of the current word
.TP
.B M\-g
Home
.TP
.B M\-G
End
.TP
.B M\-h
Up
.TP
.B M\-j
Page down
.TP
.B M\-k
Page up
.TP
.B M\-l
Down
.SH SEE ALSO
.IR dwm (1),
.IR stest (1)

@ -0,0 +1,197 @@
.TH DMENU 1 dmenu\-VERSION
.SH NAME
dmenu \- dynamic menu
.SH SYNOPSIS
.B dmenu
.RB [ \-bfiv ]
.RB [ \-l
.IR lines ]
.RB [ \-m
.IR monitor ]
.RB [ \-p
.IR prompt ]
.RB [ \-fn
.IR font ]
.RB [ \-nb
.IR color ]
.RB [ \-nf
.IR color ]
.RB [ \-sb
.IR color ]
.RB [ \-sf
.IR color ]
.RB [ \-w
.IR windowid ]
.P
.BR dmenu_run " ..."
.SH DESCRIPTION
.B dmenu
is a dynamic menu for X, which reads a list of newline\-separated items from
stdin. When the user selects an item and presses Return, their choice is printed
to stdout and dmenu terminates. Entering text will narrow the items to those
matching the tokens in the input.
.P
.B dmenu_run
is a script used by
.IR dwm (1)
which lists programs in the user's $PATH and runs the result in their $SHELL.
.SH OPTIONS
.TP
.B \-b
dmenu appears at the bottom of the screen.
.TP
.B \-c
dmenu appears centered on the screen.
.TP
.B \-f
dmenu grabs the keyboard before reading stdin if not reading from a tty. This
is faster, but will lock up X until stdin reaches end\-of\-file.
.TP
.B \-i
dmenu matches menu items case insensitively.
.TP
.BI \-l " lines"
dmenu lists items vertically, with the given number of lines.
.TP
.BI \-m " monitor"
dmenu is displayed on the monitor number supplied. Monitor numbers are starting
from 0.
.TP
.BI \-p " prompt"
defines the prompt to be displayed to the left of the input field.
.TP
.BI \-fn " font"
defines the font or font set used.
.TP
.BI \-nb " color"
defines the normal background color.
.IR #RGB ,
.IR #RRGGBB ,
and X color names are supported.
.TP
.BI \-nf " color"
defines the normal foreground color.
.TP
.BI \-sb " color"
defines the selected background color.
.TP
.BI \-sf " color"
defines the selected foreground color.
.TP
.B \-v
prints version information to stdout, then exits.
.TP
.BI \-w " windowid"
embed into windowid.
.SH USAGE
dmenu is completely controlled by the keyboard. Items are selected using the
arrow keys, page up, page down, home, and end.
.TP
.B Tab
Copy the selected item to the input field.
.TP
.B Return
Confirm selection. Prints the selected item to stdout and exits, returning
success.
.TP
.B Ctrl-Return
Confirm selection. Prints the selected item to stdout and continues.
.TP
.B Shift\-Return
Confirm input. Prints the input text to stdout and exits, returning success.
.TP
.B Escape
Exit without selecting an item, returning failure.
.TP
.B Ctrl-Left
Move cursor to the start of the current word
.TP
.B Ctrl-Right
Move cursor to the end of the current word
.TP
.B C\-a
Home
.TP
.B C\-b
Left
.TP
.B C\-c
Escape
.TP
.B C\-d
Delete
.TP
.B C\-e
End
.TP
.B C\-f
Right
.TP
.B C\-g
Escape
.TP
.B C\-h
Backspace
.TP
.B C\-i
Tab
.TP
.B C\-j
Return
.TP
.B C\-J
Shift-Return
.TP
.B C\-k
Delete line right
.TP
.B C\-m
Return
.TP
.B C\-M
Shift-Return
.TP
.B C\-n
Down
.TP
.B C\-p
Up
.TP
.B C\-u
Delete line left
.TP
.B C\-w
Delete word left
.TP
.B C\-y
Paste from primary X selection
.TP
.B C\-Y
Paste from X clipboard
.TP
.B M\-b
Move cursor to the start of the current word
.TP
.B M\-f
Move cursor to the end of the current word
.TP
.B M\-g
Home
.TP
.B M\-G
End
.TP
.B M\-h
Up
.TP
.B M\-j
Page down
.TP
.B M\-k
Page up
.TP
.B M\-l
Down
.SH SEE ALSO
.IR dwm (1),
.IR stest (1)

@ -0,0 +1,939 @@
/* See LICENSE file for copyright and license details. */
#include <ctype.h>
#include <locale.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <strings.h>
#include <time.h>
#include <unistd.h>
#include <X11/Xlib.h>
#include <X11/Xatom.h>
#include <X11/Xproto.h>
#include <X11/Xutil.h>
#ifdef XINERAMA
#include <X11/extensions/Xinerama.h>
#endif
#include <X11/Xft/Xft.h>
#include "drw.h"
#include "util.h"
/* macros */
#define INTERSECT(x,y,w,h,r) (MAX(0, MIN((x)+(w),(r).x_org+(r).width) - MAX((x),(r).x_org)) \
* MAX(0, MIN((y)+(h),(r).y_org+(r).height) - MAX((y),(r).y_org)))
#define LENGTH(X) (sizeof X / sizeof X[0])
#define TEXTW(X) (drw_fontset_getwidth(drw, (X)) + lrpad)
#define NUMBERSMAXDIGITS 100
#define NUMBERSBUFSIZE (NUMBERSMAXDIGITS * 2) + 1
#define OPAQUE 0xffU
/* enums */
enum { SchemeNorm, SchemeSel, SchemeOut, SchemeNormHighlight, SchemeSelHighlight, SchemeLast }; /* color schemes */
struct item {
char *text;
struct item *left, *right;
int out;
};
static char numbers[NUMBERSBUFSIZE] = "";
static char text[BUFSIZ] = "";
static char *embed;
static int bh, mw, mh;
static int inputw = 0, promptw;
static int lrpad; /* sum of left and right padding */
static size_t cursor;
static struct item *items = NULL;
static struct item *matches, *matchend;
static struct item *prev, *curr, *next, *sel;
static int mon = -1, screen;
static Atom clip, utf8;
static Display *dpy;
static Window root, parentwin, win;
static XIC xic;
static Drw *drw;
static Clr *scheme[SchemeLast];
static int useargb = 0;
static Visual *visual;
static int depth;
static Colormap cmap;
#include "config.h"
static int (*fstrncmp)(const char *, const char *, size_t) = strncmp;
static char *(*fstrstr)(const char *, const char *) = strstr;
static void xinitvisual();
static unsigned int
textw_clamp(const char *str, unsigned int n)
{
unsigned int w = drw_fontset_getwidth_clamp(drw, str, n) + lrpad;
return MIN(w, n);
}
static void
appenditem(struct item *item, struct item **list, struct item **last)
{
if (*last)
(*last)->right = item;
else
*list = item;
item->left = *last;
item->right = NULL;
*last = item;
}
static void
calcoffsets(void)
{
int i, n;
if (lines > 0)
n = lines * bh;
else
n = mw - (promptw + inputw + TEXTW("<") + TEXTW(">") + TEXTW(numbers));
/* calculate which items will begin the next page and previous page */
for (i = 0, next = curr; next; next = next->right)
if ((i += (lines > 0) ? bh : textw_clamp(next->text, n)) > n)
break;
for (i = 0, prev = curr; prev && prev->left; prev = prev->left)
if ((i += (lines > 0) ? bh : textw_clamp(prev->left->text, n)) > n)
break;
}
static int
max_textw(void)
{
int len = 0;
for (struct item *item = items; item && item->text; item++)
len = MAX(TEXTW(item->text), len);
return len;
}
static void
cleanup(void)
{
size_t i;
XUngrabKey(dpy, AnyKey, AnyModifier, root);
for (i = 0; i < SchemeLast; i++)
free(scheme[i]);
for (i = 0; items && items[i].text; ++i)
free(items[i].text);
free(items);
drw_free(drw);
XSync(dpy, False);
XCloseDisplay(dpy);
}
static char *
cistrstr(const char *h, const char *n)
{
size_t i;
if (!n[0])
return (char *)h;
for (; *h; ++h) {
for (i = 0; n[i] && tolower((unsigned char)n[i]) ==
tolower((unsigned char)h[i]); ++i)
;
if (n[i] == '\0')
return (char *)h;
}
return NULL;
}
static void
drawhighlights(struct item *item, int x, int y, int maxw)
{
char restorechar, tokens[sizeof text], *highlight, *token;
int indentx, highlightlen;
drw_setscheme(drw, scheme[item == sel ? SchemeSelHighlight : SchemeNormHighlight]);
strcpy(tokens, text);
for (token = strtok(tokens, " "); token; token = strtok(NULL, " ")) {
highlight = fstrstr(item->text, token);
while (highlight) {
// Move item str end, calc width for highlight indent, & restore
highlightlen = highlight - item->text;
restorechar = *highlight;
item->text[highlightlen] = '\0';
indentx = TEXTW(item->text);
item->text[highlightlen] = restorechar;
// Move highlight str end, draw highlight, & restore
restorechar = highlight[strlen(token)];
highlight[strlen(token)] = '\0';
if (indentx - (lrpad / 2) - 1 < maxw)
drw_text(
drw,
x + indentx - (lrpad / 2) - 1,
y,
MIN(maxw - indentx, TEXTW(highlight) - lrpad),
bh, 0, highlight, 0
);
highlight[strlen(token)] = restorechar;
if (strlen(highlight) - strlen(token) < strlen(token)) break;
highlight = fstrstr(highlight + strlen(token), token);
}
}
}
static int
drawitem(struct item *item, int x, int y, int w)
{
if (item == sel)
drw_setscheme(drw, scheme[SchemeSel]);
else if (item->out)
drw_setscheme(drw, scheme[SchemeOut]);
else
drw_setscheme(drw, scheme[SchemeNorm]);
int r = drw_text(drw, x, y, w, bh, lrpad / 2, item->text, 0);
drawhighlights(item, x, y, w);
return r;
}
static void
recalculatenumbers()
{
unsigned int numer = 0, denom = 0;
struct item *item;
if (matchend) {
numer++;
for (item = matchend; item && item->left; item = item->left)
numer++;
}
for (item = items; item && item->text; item++)
denom++;
snprintf(numbers, NUMBERSBUFSIZE, "%d/%d", numer, denom);
}
static void
drawmenu(void)
{
unsigned int curpos;
struct item *item;
int x = 0, y = 0, fh = drw->fonts->h, w;
drw_setscheme(drw, scheme[SchemeNorm]);
drw_rect(drw, 0, 0, mw, mh, 1, 1);
if (prompt && *prompt) {
drw_setscheme(drw, scheme[SchemeSel]);
x = drw_text(drw, x, 0, promptw, bh, lrpad / 2, prompt, 0);
}
/* draw input field */
w = (lines > 0 || !matches) ? mw - x : inputw;
drw_setscheme(drw, scheme[SchemeNorm]);
drw_text(drw, x, 0, w, bh, lrpad / 2, text, 0);
curpos = TEXTW(text) - TEXTW(&text[cursor]);
if ((curpos += lrpad / 2 - 1) < w) {
drw_setscheme(drw, scheme[SchemeNorm]);
drw_rect(drw, x + curpos, 2 + (bh - fh) / 2, 2, fh - 4, 1, 0);
}
recalculatenumbers();
if (lines > 0) {
/* draw vertical list */
for (item = curr; item != next; item = item->right)
drawitem(item, x, y += bh, mw - x);
} else if (matches) {
/* draw horizontal list */
x += inputw;
w = TEXTW("<");
if (curr->left) {
drw_setscheme(drw, scheme[SchemeNorm]);
drw_text(drw, x, 0, w, bh, lrpad / 2, "<", 0);
}
x += w;
for (item = curr; item != next; item = item->right)
x = drawitem(item, x, 0, textw_clamp(item->text, mw - x - TEXTW(">") - TEXTW(numbers)));
if (next) {
w = TEXTW(">");
drw_setscheme(drw, scheme[SchemeNorm]);
drw_text(drw, mw - w - TEXTW(numbers), 0, w, bh, lrpad / 2, ">", 0);
}
}
drw_setscheme(drw, scheme[SchemeNorm]);
drw_text(drw, mw - TEXTW(numbers), 0, TEXTW(numbers), bh, lrpad / 2, numbers, 0);
drw_map(drw, win, 0, 0, mw, mh);
}
static void
grabfocus(void)
{
struct timespec ts = { .tv_sec = 0, .tv_nsec = 10000000 };
Window focuswin;
int i, revertwin;
for (i = 0; i < 100; ++i) {
XGetInputFocus(dpy, &focuswin, &revertwin);
if (focuswin == win)
return;
XSetInputFocus(dpy, win, RevertToParent, CurrentTime);
nanosleep(&ts, NULL);
}
die("cannot grab focus");
}
static void
grabkeyboard(void)
{
struct timespec ts = { .tv_sec = 0, .tv_nsec = 1000000 };
int i;
if (embed)
return;
/* try to grab keyboard, we may have to wait for another process to ungrab */
for (i = 0; i < 1000; i++) {
if (XGrabKeyboard(dpy, DefaultRootWindow(dpy), True, GrabModeAsync,
GrabModeAsync, CurrentTime) == GrabSuccess)
return;
nanosleep(&ts, NULL);
}
die("cannot grab keyboard");
}
static void
match(void)
{
static char **tokv = NULL;
static int tokn = 0;
char buf[sizeof text], *s;
int i, tokc = 0;
size_t len, textsize;
struct item *item, *lprefix, *lsubstr, *prefixend, *substrend;
strcpy(buf, text);
/* separate input text into tokens to be matched individually */
for (s = strtok(buf, " "); s; tokv[tokc - 1] = s, s = strtok(NULL, " "))
if (++tokc > tokn && !(tokv = realloc(tokv, ++tokn * sizeof *tokv)))
die("cannot realloc %zu bytes:", tokn * sizeof *tokv);
len = tokc ? strlen(tokv[0]) : 0;
matches = lprefix = lsubstr = matchend = prefixend = substrend = NULL;
textsize = strlen(text) + 1;
for (item = items; item && item->text; item++) {
for (i = 0; i < tokc; i++)
if (!fstrstr(item->text, tokv[i]))
break;
if (i != tokc) /* not all tokens match */
continue;
/* exact matches go first, then prefixes, then substrings */
if (!tokc || !fstrncmp(text, item->text, textsize))
appenditem(item, &matches, &matchend);
else if (!fstrncmp(tokv[0], item->text, len))
appenditem(item, &lprefix, &prefixend);
else
appenditem(item, &lsubstr, &substrend);
}
if (lprefix) {
if (matches) {
matchend->right = lprefix;
lprefix->left = matchend;
} else
matches = lprefix;
matchend = prefixend;
}
if (lsubstr) {
if (matches) {
matchend->right = lsubstr;
lsubstr->left = matchend;
} else
matches = lsubstr;
matchend = substrend;
}
curr = sel = matches;
calcoffsets();
}
static void
insert(const char *str, ssize_t n)
{
if (strlen(text) + n > sizeof text - 1)
return;
/* move existing text out of the way, insert new text, and update cursor */
memmove(&text[cursor + n], &text[cursor], sizeof text - cursor - MAX(n, 0));
if (n > 0)
memcpy(&text[cursor], str, n);
cursor += n;
match();
}
static size_t
nextrune(int inc)
{
ssize_t n;
/* return location of next utf8 rune in the given direction (+1 or -1) */
for (n = cursor + inc; n + inc >= 0 && (text[n] & 0xc0) == 0x80; n += inc)
;
return n;
}
static void
movewordedge(int dir)
{
if (dir < 0) { /* move cursor to the start of the word*/
while (cursor > 0 && strchr(worddelimiters, text[nextrune(-1)]))
cursor = nextrune(-1);
while (cursor > 0 && !strchr(worddelimiters, text[nextrune(-1)]))
cursor = nextrune(-1);
} else { /* move cursor to the end of the word */
while (text[cursor] && strchr(worddelimiters, text[cursor]))
cursor = nextrune(+1);
while (text[cursor] && !strchr(worddelimiters, text[cursor]))
cursor = nextrune(+1);
}
}
static void
keypress(XKeyEvent *ev)
{
char buf[64];
int len;
KeySym ksym = NoSymbol;
Status status;
len = XmbLookupString(xic, ev, buf, sizeof buf, &ksym, &status);
switch (status) {
default: /* XLookupNone, XBufferOverflow */
return;
case XLookupChars: /* composed string from input method */
goto insert;
case XLookupKeySym:
case XLookupBoth: /* a KeySym and a string are returned: use keysym */
break;
}
if (ev->state & ControlMask) {
switch(ksym) {
case XK_a: ksym = XK_Home; break;
case XK_b: ksym = XK_Left; break;
case XK_c: ksym = XK_Escape; break;
case XK_d: ksym = XK_Delete; break;
case XK_e: ksym = XK_End; break;
case XK_f: ksym = XK_Right; break;
case XK_g: ksym = XK_Escape; break;
case XK_h: ksym = XK_BackSpace; break;
case XK_i: ksym = XK_Tab; break;
case XK_j: /* fallthrough */
case XK_J: /* fallthrough */
case XK_m: /* fallthrough */
case XK_M: ksym = XK_Return; ev->state &= ~ControlMask; break;
case XK_n: ksym = XK_Down; break;
case XK_p: ksym = XK_Up; break;
case XK_k: /* delete right */
text[cursor] = '\0';
match();
break;
case XK_u: /* delete left */
insert(NULL, 0 - cursor);
break;
case XK_w: /* delete word */
while (cursor > 0 && strchr(worddelimiters, text[nextrune(-1)]))
insert(NULL, nextrune(-1) - cursor);
while (cursor > 0 && !strchr(worddelimiters, text[nextrune(-1)]))
insert(NULL, nextrune(-1) - cursor);
break;
case XK_y: /* paste selection */
case XK_Y:
XConvertSelection(dpy, (ev->state & ShiftMask) ? clip : XA_PRIMARY,
utf8, utf8, win, CurrentTime);
return;
case XK_Left:
case XK_KP_Left:
movewordedge(-1);
goto draw;
case XK_Right:
case XK_KP_Right:
movewordedge(+1);
goto draw;
case XK_Return:
case XK_KP_Enter:
break;
case XK_bracketleft:
cleanup();
exit(1);
default:
return;
}
} else if (ev->state & Mod1Mask) {
switch(ksym) {
case XK_b:
movewordedge(-1);
goto draw;
case XK_f:
movewordedge(+1);
goto draw;
case XK_g: ksym = XK_Home; break;
case XK_G: ksym = XK_End; break;
case XK_h: ksym = XK_Up; break;
case XK_j: ksym = XK_Next; break;
case XK_k: ksym = XK_Prior; break;
case XK_l: ksym = XK_Down; break;
default:
return;
}
}
switch(ksym) {
default:
insert:
if (!iscntrl((unsigned char)*buf))
insert(buf, len);
break;
case XK_Delete:
case XK_KP_Delete:
if (text[cursor] == '\0')
return;
cursor = nextrune(+1);
/* fallthrough */
case XK_BackSpace:
if (cursor == 0)
return;
insert(NULL, nextrune(-1) - cursor);
break;
case XK_End:
case XK_KP_End:
if (text[cursor] != '\0') {
cursor = strlen(text);
break;
}
if (next) {
/* jump to end of list and position items in reverse */
curr = matchend;
calcoffsets();
curr = prev;
calcoffsets();
while (next && (curr = curr->right))
calcoffsets();
}
sel = matchend;
break;
case XK_Escape:
cleanup();
exit(1);
case XK_Home:
case XK_KP_Home:
if (sel == matches) {
cursor = 0;
break;
}
sel = curr = matches;
calcoffsets();
break;
case XK_Left:
case XK_KP_Left:
if (cursor > 0 && (!sel || !sel->left || lines > 0)) {
cursor = nextrune(-1);
break;
}
if (lines > 0)
return;
/* fallthrough */
case XK_Up:
case XK_KP_Up:
if (sel && sel->left && (sel = sel->left)->right == curr) {
curr = prev;
calcoffsets();
}
break;
case XK_Next:
case XK_KP_Next:
if (!next)
return;
sel = curr = next;
calcoffsets();
break;
case XK_Prior:
case XK_KP_Prior:
if (!prev)
return;
sel = curr = prev;
calcoffsets();
break;
case XK_Return:
case XK_KP_Enter:
puts((sel && !(ev->state & ShiftMask)) ? sel->text : text);
if (!(ev->state & ControlMask)) {
cleanup();
exit(0);
}
if (sel)
sel->out = 1;
break;
case XK_Right:
case XK_KP_Right:
if (text[cursor] != '\0') {
cursor = nextrune(+1);
break;
}
if (lines > 0)
return;
/* fallthrough */
case XK_Down:
case XK_KP_Down:
if (sel && sel->right && (sel = sel->right) == next) {
curr = next;
calcoffsets();
}
break;
case XK_Tab:
if (!sel)
return;
cursor = strnlen(sel->text, sizeof text - 1);
memcpy(text, sel->text, cursor);
text[cursor] = '\0';
match();
break;
}
draw:
drawmenu();
}
static void
paste(void)
{
char *p, *q;
int di;
unsigned long dl;
Atom da;
/* we have been given the current selection, now insert it into input */
if (XGetWindowProperty(dpy, win, utf8, 0, (sizeof text / 4) + 1, False,
utf8, &da, &di, &dl, &dl, (unsigned char **)&p)
== Success && p) {
insert(p, (q = strchr(p, '\n')) ? q - p : (ssize_t)strlen(p));
XFree(p);
}
drawmenu();
}
static void
readstdin(void)
{
char *line = NULL;
size_t i, junk, itemsiz = 0;
ssize_t len;
/* read each line from stdin and add it to the item list */
for (i = 0; (len = getline(&line, &junk, stdin)) != -1; i++) {
if (i + 1 >= itemsiz) {
itemsiz += 256;
if (!(items = realloc(items, itemsiz * sizeof(*items))))
die("cannot realloc %zu bytes:", itemsiz * sizeof(*items));
}
if (line[len - 1] == '\n')
line[len - 1] = '\0';
items[i].text = line;
items[i].out = 0;
line = NULL; /* next call of getline() allocates a new line */
}
free(line);
if (items)
items[i].text = NULL;
lines = MIN(lines, i);
}
static void
run(void)
{
XEvent ev;
while (!XNextEvent(dpy, &ev)) {
if (XFilterEvent(&ev, win))
continue;
switch(ev.type) {
case DestroyNotify:
if (ev.xdestroywindow.window != win)
break;
cleanup();
exit(1);
case Expose:
if (ev.xexpose.count == 0)
drw_map(drw, win, 0, 0, mw, mh);
break;
case FocusIn:
/* regrab focus from parent window */
if (ev.xfocus.window != win)
grabfocus();
break;
case KeyPress:
keypress(&ev.xkey);
break;
case SelectionNotify:
if (ev.xselection.property == utf8)
paste();
break;
case VisibilityNotify:
if (ev.xvisibility.state != VisibilityUnobscured)
XRaiseWindow(dpy, win);
break;
}
}
}
static void
setup(void)
{
int x, y, i, j;
unsigned int du;
XSetWindowAttributes swa;
XIM xim;
Window w, dw, *dws;
XWindowAttributes wa;
XClassHint ch = {"dmenu", "dmenu"};
#ifdef XINERAMA
XineramaScreenInfo *info;
Window pw;
int a, di, n, area = 0;
#endif
/* init appearance */
for (j = 0; j < SchemeLast; j++)
scheme[j] = drw_scm_create(drw, colors[j], alphas[i], 2);
clip = XInternAtom(dpy, "CLIPBOARD", False);
utf8 = XInternAtom(dpy, "UTF8_STRING", False);
/* calculate menu geometry */
bh = drw->fonts->h + 2;
bh = MAX(bh,lineheight); /* make a menu line AT LEAST 'lineheight' tall */
lines = MAX(lines, 0);
mh = (lines + 1) * bh;
promptw = (prompt && *prompt) ? TEXTW(prompt) - lrpad / 4 : 0;
#ifdef XINERAMA
i = 0;
if (parentwin == root && (info = XineramaQueryScreens(dpy, &n))) {
XGetInputFocus(dpy, &w, &di);
if (mon >= 0 && mon < n)
i = mon;
else if (w != root && w != PointerRoot && w != None) {
/* find top-level window containing current input focus */
do {
if (XQueryTree(dpy, (pw = w), &dw, &w, &dws, &du) && dws)
XFree(dws);
} while (w != root && w != pw);
/* find xinerama screen with which the window intersects most */
if (XGetWindowAttributes(dpy, pw, &wa))
for (j = 0; j < n; j++)
if ((a = INTERSECT(wa.x, wa.y, wa.width, wa.height, info[j])) > area) {
area = a;
i = j;
}
}
/* no focused window is on screen, so use pointer location instead */
if (mon < 0 && !area && XQueryPointer(dpy, root, &dw, &dw, &x, &y, &di, &di, &du))
for (i = 0; i < n; i++)
if (INTERSECT(x, y, 1, 1, info[i]) != 0)
break;
if (centered) {
mw = MIN(MAX(max_textw() + promptw, min_width), info[i].width);
x = info[i].x_org + ((info[i].width - mw) / 2);
y = info[i].y_org + ((info[i].height - mh) / 2);
} else {
x = info[i].x_org;
y = info[i].y_org + (topbar ? 0 : info[i].height - mh);
mw = info[i].width;
}
XFree(info);
} else
#endif
{
if (!XGetWindowAttributes(dpy, parentwin, &wa))
die("could not get embedding window attributes: 0x%lx",
parentwin);
if (centered) {
mw = MIN(MAX(max_textw() + promptw, min_width), wa.width);
x = (wa.width - mw) / 2;
y = (wa.height - mh) / 2;
} else {
x = 0;
y = topbar ? 0 : wa.height - mh;
mw = wa.width;
}
}
promptw = (prompt && *prompt) ? TEXTW(prompt) - lrpad / 4 : 0;
inputw = mw / 3; /* input width: ~33% of monitor width */
match();
/* create menu window */
swa.override_redirect = True;
swa.background_pixel = 0;
swa.border_pixel = 0;
swa.colormap = cmap;
swa.event_mask = ExposureMask | KeyPressMask | VisibilityChangeMask;
win = XCreateWindow(dpy, parentwin, x, y, mw, mh, border_width,
depth, CopyFromParent, visual,
CWOverrideRedirect | CWBackPixel | CWBorderPixel | CWColormap |
CWEventMask, &swa);
XSetWindowBorder(dpy, win, scheme[SchemeSel][ColBg].pixel);
XSetClassHint(dpy, win, &ch);
/* input methods */
if ((xim = XOpenIM(dpy, NULL, NULL, NULL)) == NULL)
die("XOpenIM failed: could not open input device");
xic = XCreateIC(xim, XNInputStyle, XIMPreeditNothing | XIMStatusNothing,
XNClientWindow, win, XNFocusWindow, win, NULL);
XMapRaised(dpy, win);
if (embed) {
XSelectInput(dpy, parentwin, FocusChangeMask | SubstructureNotifyMask);
if (XQueryTree(dpy, parentwin, &dw, &w, &dws, &du) && dws) {
for (i = 0; i < du && dws[i] != win; ++i)
XSelectInput(dpy, dws[i], FocusChangeMask);
XFree(dws);
}
grabfocus();
}
drw_resize(drw, mw, mh);
drawmenu();
}
static void
usage(void)
{
die("usage: dmenu [-bfiv] [-l lines] [-h height] [-p prompt] [-fn font] [-m monitor]\n"
" [-nb color] [-nf color] [-sb color] [-sf color] [-w windowid]");
}
int
main(int argc, char *argv[])
{
XWindowAttributes wa;
int i, fast = 0;
for (i = 1; i < argc; i++)
/* these options take no arguments */
if (!strcmp(argv[i], "-v")) { /* prints version information */
puts("dmenu-"VERSION);
exit(0);
} else if (!strcmp(argv[i], "-b")) /* appears at the bottom of the screen */
topbar = 0;
else if (!strcmp(argv[i], "-f")) /* grabs keyboard before reading stdin */
fast = 1;
else if (!strcmp(argv[i], "-c")) /* centers dmenu on screen */
centered = 1;
else if (!strcmp(argv[i], "-i")) { /* case-insensitive item matching */
fstrncmp = strncasecmp;
fstrstr = cistrstr;
} else if (i + 1 == argc)
usage();
/* these options take one argument */
else if (!strcmp(argv[i], "-l")) /* number of lines in vertical list */
lines = atoi(argv[++i]);
else if (!strcmp(argv[i], "-h")) { /* minimum height of one menu line */
lineheight = atoi(argv[++i]);
lineheight = MAX(lineheight, min_lineheight);
}
else if (!strcmp(argv[i], "-m"))
mon = atoi(argv[++i]);
else if (!strcmp(argv[i], "-p")) /* adds prompt to left of input field */
prompt = argv[++i];
else if (!strcmp(argv[i], "-fn")) /* font or font set */
fonts[0] = argv[++i];
else if (!strcmp(argv[i], "-nb")) /* normal background color */
colors[SchemeNorm][ColBg] = argv[++i];
else if (!strcmp(argv[i], "-nf")) /* normal foreground color */
colors[SchemeNorm][ColFg] = argv[++i];
else if (!strcmp(argv[i], "-sb")) /* selected background color */
colors[SchemeSel][ColBg] = argv[++i];
else if (!strcmp(argv[i], "-sf")) /* selected foreground color */
colors[SchemeSel][ColFg] = argv[++i];
else if (!strcmp(argv[i], "-w")) /* embedding window id */
embed = argv[++i];
else
usage();
if (!setlocale(LC_CTYPE, "") || !XSupportsLocale())
fputs("warning: no locale support\n", stderr);
if (!(dpy = XOpenDisplay(NULL)))
die("cannot open display");
screen = DefaultScreen(dpy);
root = RootWindow(dpy, screen);
if (!embed || !(parentwin = strtol(embed, NULL, 0)))
parentwin = root;
if (!XGetWindowAttributes(dpy, parentwin, &wa))
die("could not get embedding window attributes: 0x%lx",
parentwin);
xinitvisual();
xinitvisual();
drw = drw_create(dpy, screen, root, wa.width, wa.height, visual, depth, cmap);
if (!drw_fontset_create(drw, fonts, LENGTH(fonts)))
die("no fonts could be loaded.");
lrpad = drw->fonts->h;
#ifdef __OpenBSD__
if (pledge("stdio rpath", NULL) == -1)
die("pledge");
#endif
if (fast && !isatty(0)) {
grabkeyboard();
readstdin();
} else {
readstdin();
grabkeyboard();
}
setup();
run();
return 1; /* unreachable */
}
void
xinitvisual()
{
XVisualInfo *infos;
XRenderPictFormat *fmt;
int nitems;
int i;
XVisualInfo tpl = {
.screen = screen,
.depth = 32,
.class = TrueColor
};
long masks = VisualScreenMask | VisualDepthMask | VisualClassMask;
infos = XGetVisualInfo(dpy, masks, &tpl, &nitems);
visual = NULL;
for(i = 0; i < nitems; i ++) {
fmt = XRenderFindVisualFormat(dpy, infos[i].visual);
if (fmt->type == PictTypeDirect && fmt->direct.alphaMask) {
visual = infos[i].visual;
depth = infos[i].depth;
cmap = XCreateColormap(dpy, root, visual, AllocNone);
useargb = 1;
break;
}
}
XFree(infos);
if (! visual) {
visual = DefaultVisual(dpy, screen);
depth = DefaultDepth(dpy, screen);
cmap = DefaultColormap(dpy, screen);
}
}

@ -0,0 +1,887 @@
/* See LICENSE file for copyright and license details. */
#include <ctype.h>
#include <locale.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <strings.h>
#include <time.h>
#include <unistd.h>
#include <X11/Xlib.h>
#include <X11/Xatom.h>
#include <X11/Xutil.h>
#ifdef XINERAMA
#include <X11/extensions/Xinerama.h>
#endif
#include <X11/Xft/Xft.h>
#include "drw.h"
#include "util.h"
/* macros */
#define INTERSECT(x,y,w,h,r) (MAX(0, MIN((x)+(w),(r).x_org+(r).width) - MAX((x),(r).x_org)) \
* MAX(0, MIN((y)+(h),(r).y_org+(r).height) - MAX((y),(r).y_org)))
#define LENGTH(X) (sizeof X / sizeof X[0])
#define TEXTW(X) (drw_fontset_getwidth(drw, (X)) + lrpad)
#define NUMBERSMAXDIGITS 100
#define NUMBERSBUFSIZE (NUMBERSMAXDIGITS * 2) + 1
/* enums */
enum { SchemeNorm, SchemeSel, SchemeOut, SchemeNormHighlight, SchemeSelHighlight, SchemeLast }; /* color schemes */
struct item {
char *text;
struct item *left, *right;
int out;
};
static char numbers[NUMBERSBUFSIZE] = "";
static char text[BUFSIZ] = "";
static char *embed;
static int bh, mw, mh;
static int inputw = 0, promptw;
static int lrpad; /* sum of left and right padding */
static size_t cursor;
static struct item *items = NULL;
static struct item *matches, *matchend;
static struct item *prev, *curr, *next, *sel;
static int mon = -1, screen;
static Atom clip, utf8;
static Display *dpy;
static Window root, parentwin, win;
static XIC xic;
static Drw *drw;
static Clr *scheme[SchemeLast];
#include "config.h"
static int (*fstrncmp)(const char *, const char *, size_t) = strncmp;
static char *(*fstrstr)(const char *, const char *) = strstr;
static unsigned int
textw_clamp(const char *str, unsigned int n)
{
unsigned int w = drw_fontset_getwidth_clamp(drw, str, n) + lrpad;
return MIN(w, n);
}
static void
appenditem(struct item *item, struct item **list, struct item **last)
{
if (*last)
(*last)->right = item;
else
*list = item;
item->left = *last;
item->right = NULL;
*last = item;
}
static void
calcoffsets(void)
{
int i, n;
if (lines > 0)
n = lines * bh;
else
n = mw - (promptw + inputw + TEXTW("<") + TEXTW(">") + TEXTW(numbers));
/* calculate which items will begin the next page and previous page */
for (i = 0, next = curr; next; next = next->right)
if ((i += (lines > 0) ? bh : textw_clamp(next->text, n)) > n)
break;
for (i = 0, prev = curr; prev && prev->left; prev = prev->left)
if ((i += (lines > 0) ? bh : textw_clamp(prev->left->text, n)) > n)
break;
}
static int
max_textw(void)
{
int len = 0;
for (struct item *item = items; item && item->text; item++)
len = MAX(TEXTW(item->text), len);
return len;
}
static void
cleanup(void)
{
size_t i;
XUngrabKey(dpy, AnyKey, AnyModifier, root);
for (i = 0; i < SchemeLast; i++)
free(scheme[i]);
for (i = 0; items && items[i].text; ++i)
free(items[i].text);
free(items);
drw_free(drw);
XSync(dpy, False);
XCloseDisplay(dpy);
}
static char *
cistrstr(const char *h, const char *n)
{
size_t i;
if (!n[0])
return (char *)h;
for (; *h; ++h) {
for (i = 0; n[i] && tolower((unsigned char)n[i]) ==
tolower((unsigned char)h[i]); ++i)
;
if (n[i] == '\0')
return (char *)h;
}
return NULL;
}
static void
drawhighlights(struct item *item, int x, int y, int maxw)
{
char restorechar, tokens[sizeof text], *highlight, *token;
int indentx, highlightlen;
drw_setscheme(drw, scheme[item == sel ? SchemeSelHighlight : SchemeNormHighlight]);
strcpy(tokens, text);
for (token = strtok(tokens, " "); token; token = strtok(NULL, " ")) {
highlight = fstrstr(item->text, token);
while (highlight) {
// Move item str end, calc width for highlight indent, & restore
highlightlen = highlight - item->text;
restorechar = *highlight;
item->text[highlightlen] = '\0';
indentx = TEXTW(item->text);
item->text[highlightlen] = restorechar;
// Move highlight str end, draw highlight, & restore
restorechar = highlight[strlen(token)];
highlight[strlen(token)] = '\0';
if (indentx - (lrpad / 2) - 1 < maxw)
drw_text(
drw,
x + indentx - (lrpad / 2) - 1,
y,
MIN(maxw - indentx, TEXTW(highlight) - lrpad),
bh, 0, highlight, 0
);
highlight[strlen(token)] = restorechar;
if (strlen(highlight) - strlen(token) < strlen(token)) break;
highlight = fstrstr(highlight + strlen(token), token);
}
}
}
static int
drawitem(struct item *item, int x, int y, int w)
{
if (item == sel)
drw_setscheme(drw, scheme[SchemeSel]);
else if (item->out)
drw_setscheme(drw, scheme[SchemeOut]);
else
drw_setscheme(drw, scheme[SchemeNorm]);
int r = drw_text(drw, x, y, w, bh, lrpad / 2, item->text, 0);
drawhighlights(item, x, y, w);
return r;
}
static void
recalculatenumbers()
{
unsigned int numer = 0, denom = 0;
struct item *item;
if (matchend) {
numer++;
for (item = matchend; item && item->left; item = item->left)
numer++;
}
for (item = items; item && item->text; item++)
denom++;
snprintf(numbers, NUMBERSBUFSIZE, "%d/%d", numer, denom);
}
static void
drawmenu(void)
{
unsigned int curpos;
struct item *item;
int x = 0, y = 0, fh = drw->fonts->h, w;
drw_setscheme(drw, scheme[SchemeNorm]);
drw_rect(drw, 0, 0, mw, mh, 1, 1);
if (prompt && *prompt) {
drw_setscheme(drw, scheme[SchemeSel]);
x = drw_text(drw, x, 0, promptw, bh, lrpad / 2, prompt, 0);
}
/* draw input field */
w = (lines > 0 || !matches) ? mw - x : inputw;
drw_setscheme(drw, scheme[SchemeNorm]);
drw_text(drw, x, 0, w, bh, lrpad / 2, text, 0);
curpos = TEXTW(text) - TEXTW(&text[cursor]);
if ((curpos += lrpad / 2 - 1) < w) {
drw_setscheme(drw, scheme[SchemeNorm]);
drw_rect(drw, x + curpos, 2 + (bh - fh) / 2, 2, fh - 4, 1, 0);
}
recalculatenumbers();
if (lines > 0) {
/* draw vertical list */
for (item = curr; item != next; item = item->right)
drawitem(item, x, y += bh, mw - x);
} else if (matches) {
/* draw horizontal list */
x += inputw;
w = TEXTW("<");
if (curr->left) {
drw_setscheme(drw, scheme[SchemeNorm]);
drw_text(drw, x, 0, w, bh, lrpad / 2, "<", 0);
}
x += w;
for (item = curr; item != next; item = item->right)
x = drawitem(item, x, 0, textw_clamp(item->text, mw - x - TEXTW(">") - TEXTW(numbers)));
if (next) {
w = TEXTW(">");
drw_setscheme(drw, scheme[SchemeNorm]);
drw_text(drw, mw - w - TEXTW(numbers), 0, w, bh, lrpad / 2, ">", 0);
}
}
drw_setscheme(drw, scheme[SchemeNorm]);
drw_text(drw, mw - TEXTW(numbers), 0, TEXTW(numbers), bh, lrpad / 2, numbers, 0);
drw_map(drw, win, 0, 0, mw, mh);
}
static void
grabfocus(void)
{
struct timespec ts = { .tv_sec = 0, .tv_nsec = 10000000 };
Window focuswin;
int i, revertwin;
for (i = 0; i < 100; ++i) {
XGetInputFocus(dpy, &focuswin, &revertwin);
if (focuswin == win)
return;
XSetInputFocus(dpy, win, RevertToParent, CurrentTime);
nanosleep(&ts, NULL);
}
die("cannot grab focus");
}
static void
grabkeyboard(void)
{
struct timespec ts = { .tv_sec = 0, .tv_nsec = 1000000 };
int i;
if (embed)
return;
/* try to grab keyboard, we may have to wait for another process to ungrab */
for (i = 0; i < 1000; i++) {
if (XGrabKeyboard(dpy, DefaultRootWindow(dpy), True, GrabModeAsync,
GrabModeAsync, CurrentTime) == GrabSuccess)
return;
nanosleep(&ts, NULL);
}
die("cannot grab keyboard");
}
static void
match(void)
{
static char **tokv = NULL;
static int tokn = 0;
char buf[sizeof text], *s;
int i, tokc = 0;
size_t len, textsize;
struct item *item, *lprefix, *lsubstr, *prefixend, *substrend;
strcpy(buf, text);
/* separate input text into tokens to be matched individually */
for (s = strtok(buf, " "); s; tokv[tokc - 1] = s, s = strtok(NULL, " "))
if (++tokc > tokn && !(tokv = realloc(tokv, ++tokn * sizeof *tokv)))
die("cannot realloc %zu bytes:", tokn * sizeof *tokv);
len = tokc ? strlen(tokv[0]) : 0;
matches = lprefix = lsubstr = matchend = prefixend = substrend = NULL;
textsize = strlen(text) + 1;
for (item = items; item && item->text; item++) {
for (i = 0; i < tokc; i++)
if (!fstrstr(item->text, tokv[i]))
break;
if (i != tokc) /* not all tokens match */
continue;
/* exact matches go first, then prefixes, then substrings */
if (!tokc || !fstrncmp(text, item->text, textsize))
appenditem(item, &matches, &matchend);
else if (!fstrncmp(tokv[0], item->text, len))
appenditem(item, &lprefix, &prefixend);
else
appenditem(item, &lsubstr, &substrend);
}
if (lprefix) {
if (matches) {
matchend->right = lprefix;
lprefix->left = matchend;
} else
matches = lprefix;
matchend = prefixend;
}
if (lsubstr) {
if (matches) {
matchend->right = lsubstr;
lsubstr->left = matchend;
} else
matches = lsubstr;
matchend = substrend;
}
curr = sel = matches;
calcoffsets();
}
static void
insert(const char *str, ssize_t n)
{
if (strlen(text) + n > sizeof text - 1)
return;
/* move existing text out of the way, insert new text, and update cursor */
memmove(&text[cursor + n], &text[cursor], sizeof text - cursor - MAX(n, 0));
if (n > 0)
memcpy(&text[cursor], str, n);
cursor += n;
match();
}
static size_t
nextrune(int inc)
{
ssize_t n;
/* return location of next utf8 rune in the given direction (+1 or -1) */
for (n = cursor + inc; n + inc >= 0 && (text[n] & 0xc0) == 0x80; n += inc)
;
return n;
}
static void
movewordedge(int dir)
{
if (dir < 0) { /* move cursor to the start of the word*/
while (cursor > 0 && strchr(worddelimiters, text[nextrune(-1)]))
cursor = nextrune(-1);
while (cursor > 0 && !strchr(worddelimiters, text[nextrune(-1)]))
cursor = nextrune(-1);
} else { /* move cursor to the end of the word */
while (text[cursor] && strchr(worddelimiters, text[cursor]))
cursor = nextrune(+1);
while (text[cursor] && !strchr(worddelimiters, text[cursor]))
cursor = nextrune(+1);
}
}
static void
keypress(XKeyEvent *ev)
{
char buf[64];
int len;
KeySym ksym = NoSymbol;
Status status;
len = XmbLookupString(xic, ev, buf, sizeof buf, &ksym, &status);
switch (status) {
default: /* XLookupNone, XBufferOverflow */
return;
case XLookupChars: /* composed string from input method */
goto insert;
case XLookupKeySym:
case XLookupBoth: /* a KeySym and a string are returned: use keysym */
break;
}
if (ev->state & ControlMask) {
switch(ksym) {
case XK_a: ksym = XK_Home; break;
case XK_b: ksym = XK_Left; break;
case XK_c: ksym = XK_Escape; break;
case XK_d: ksym = XK_Delete; break;
case XK_e: ksym = XK_End; break;
case XK_f: ksym = XK_Right; break;
case XK_g: ksym = XK_Escape; break;
case XK_h: ksym = XK_BackSpace; break;
case XK_i: ksym = XK_Tab; break;
case XK_j: /* fallthrough */
case XK_J: /* fallthrough */
case XK_m: /* fallthrough */
case XK_M: ksym = XK_Return; ev->state &= ~ControlMask; break;
case XK_n: ksym = XK_Down; break;
case XK_p: ksym = XK_Up; break;
case XK_k: /* delete right */
text[cursor] = '\0';
match();
break;
case XK_u: /* delete left */
insert(NULL, 0 - cursor);
break;
case XK_w: /* delete word */
while (cursor > 0 && strchr(worddelimiters, text[nextrune(-1)]))
insert(NULL, nextrune(-1) - cursor);
while (cursor > 0 && !strchr(worddelimiters, text[nextrune(-1)]))
insert(NULL, nextrune(-1) - cursor);
break;
case XK_y: /* paste selection */
case XK_Y:
XConvertSelection(dpy, (ev->state & ShiftMask) ? clip : XA_PRIMARY,
utf8, utf8, win, CurrentTime);
return;
case XK_Left:
case XK_KP_Left:
movewordedge(-1);
goto draw;
case XK_Right:
case XK_KP_Right:
movewordedge(+1);
goto draw;
case XK_Return:
case XK_KP_Enter:
break;
case XK_bracketleft:
cleanup();
exit(1);
default:
return;
}
} else if (ev->state & Mod1Mask) {
switch(ksym) {
case XK_b:
movewordedge(-1);
goto draw;
case XK_f:
movewordedge(+1);
goto draw;
case XK_g: ksym = XK_Home; break;
case XK_G: ksym = XK_End; break;
case XK_h: ksym = XK_Up; break;
case XK_j: ksym = XK_Next; break;
case XK_k: ksym = XK_Prior; break;
case XK_l: ksym = XK_Down; break;
default:
return;
}
}
switch(ksym) {
default:
insert:
if (!iscntrl((unsigned char)*buf))
insert(buf, len);
break;
case XK_Delete:
case XK_KP_Delete:
if (text[cursor] == '\0')
return;
cursor = nextrune(+1);
/* fallthrough */
case XK_BackSpace:
if (cursor == 0)
return;
insert(NULL, nextrune(-1) - cursor);
break;
case XK_End:
case XK_KP_End:
if (text[cursor] != '\0') {
cursor = strlen(text);
break;
}
if (next) {
/* jump to end of list and position items in reverse */
curr = matchend;
calcoffsets();
curr = prev;
calcoffsets();
while (next && (curr = curr->right))
calcoffsets();
}
sel = matchend;
break;
case XK_Escape:
cleanup();
exit(1);
case XK_Home:
case XK_KP_Home:
if (sel == matches) {
cursor = 0;
break;
}
sel = curr = matches;
calcoffsets();
break;
case XK_Left:
case XK_KP_Left:
if (cursor > 0 && (!sel || !sel->left || lines > 0)) {
cursor = nextrune(-1);
break;
}
if (lines > 0)
return;
/* fallthrough */
case XK_Up:
case XK_KP_Up:
if (sel && sel->left && (sel = sel->left)->right == curr) {
curr = prev;
calcoffsets();
}
break;
case XK_Next:
case XK_KP_Next:
if (!next)
return;
sel = curr = next;
calcoffsets();
break;
case XK_Prior:
case XK_KP_Prior:
if (!prev)
return;
sel = curr = prev;
calcoffsets();
break;
case XK_Return:
case XK_KP_Enter:
puts((sel && !(ev->state & ShiftMask)) ? sel->text : text);
if (!(ev->state & ControlMask)) {
cleanup();
exit(0);
}
if (sel)
sel->out = 1;
break;
case XK_Right:
case XK_KP_Right:
if (text[cursor] != '\0') {
cursor = nextrune(+1);
break;
}
if (lines > 0)
return;
/* fallthrough */
case XK_Down:
case XK_KP_Down:
if (sel && sel->right && (sel = sel->right) == next) {
curr = next;
calcoffsets();
}
break;
case XK_Tab:
if (!sel)
return;
cursor = strnlen(sel->text, sizeof text - 1);
memcpy(text, sel->text, cursor);
text[cursor] = '\0';
match();
break;
}
draw:
drawmenu();
}
static void
paste(void)
{
char *p, *q;
int di;
unsigned long dl;
Atom da;
/* we have been given the current selection, now insert it into input */
if (XGetWindowProperty(dpy, win, utf8, 0, (sizeof text / 4) + 1, False,
utf8, &da, &di, &dl, &dl, (unsigned char **)&p)
== Success && p) {
insert(p, (q = strchr(p, '\n')) ? q - p : (ssize_t)strlen(p));
XFree(p);
}
drawmenu();
}
static void
readstdin(void)
{
char *line = NULL;
size_t i, junk, itemsiz = 0;
ssize_t len;
/* read each line from stdin and add it to the item list */
for (i = 0; (len = getline(&line, &junk, stdin)) != -1; i++) {
if (i + 1 >= itemsiz) {
itemsiz += 256;
if (!(items = realloc(items, itemsiz * sizeof(*items))))
die("cannot realloc %zu bytes:", itemsiz * sizeof(*items));
}
if (line[len - 1] == '\n')
line[len - 1] = '\0';
items[i].text = line;
items[i].out = 0;
line = NULL; /* next call of getline() allocates a new line */
}
free(line);
if (items)
items[i].text = NULL;
lines = MIN(lines, i);
}
static void
run(void)
{
XEvent ev;
while (!XNextEvent(dpy, &ev)) {
if (XFilterEvent(&ev, win))
continue;
switch(ev.type) {
case DestroyNotify:
if (ev.xdestroywindow.window != win)
break;
cleanup();
exit(1);
case Expose:
if (ev.xexpose.count == 0)
drw_map(drw, win, 0, 0, mw, mh);
break;
case FocusIn:
/* regrab focus from parent window */
if (ev.xfocus.window != win)
grabfocus();
break;
case KeyPress:
keypress(&ev.xkey);
break;
case SelectionNotify:
if (ev.xselection.property == utf8)
paste();
break;
case VisibilityNotify:
if (ev.xvisibility.state != VisibilityUnobscured)
XRaiseWindow(dpy, win);
break;
}
}
}
static void
setup(void)
{
int x, y, i, j;
unsigned int du;
XSetWindowAttributes swa;
XIM xim;
Window w, dw, *dws;
XWindowAttributes wa;
XClassHint ch = {"dmenu", "dmenu"};
#ifdef XINERAMA
XineramaScreenInfo *info;
Window pw;
int a, di, n, area = 0;
#endif
/* init appearance */
for (j = 0; j < SchemeLast; j++)
scheme[j] = drw_scm_create(drw, colors[j], 2);
clip = XInternAtom(dpy, "CLIPBOARD", False);
utf8 = XInternAtom(dpy, "UTF8_STRING", False);
/* calculate menu geometry */
bh = drw->fonts->h + 2;
bh = MAX(bh,lineheight); /* make a menu line AT LEAST 'lineheight' tall */
lines = MAX(lines, 0);
mh = (lines + 1) * bh;
promptw = (prompt && *prompt) ? TEXTW(prompt) - lrpad / 4 : 0;
#ifdef XINERAMA
i = 0;
if (parentwin == root && (info = XineramaQueryScreens(dpy, &n))) {
XGetInputFocus(dpy, &w, &di);
if (mon >= 0 && mon < n)
i = mon;
else if (w != root && w != PointerRoot && w != None) {
/* find top-level window containing current input focus */
do {
if (XQueryTree(dpy, (pw = w), &dw, &w, &dws, &du) && dws)
XFree(dws);
} while (w != root && w != pw);
/* find xinerama screen with which the window intersects most */
if (XGetWindowAttributes(dpy, pw, &wa))
for (j = 0; j < n; j++)
if ((a = INTERSECT(wa.x, wa.y, wa.width, wa.height, info[j])) > area) {
area = a;
i = j;
}
}
/* no focused window is on screen, so use pointer location instead */
if (mon < 0 && !area && XQueryPointer(dpy, root, &dw, &dw, &x, &y, &di, &di, &du))
for (i = 0; i < n; i++)
if (INTERSECT(x, y, 1, 1, info[i]) != 0)
break;
if (centered) {
mw = MIN(MAX(max_textw() + promptw, min_width), info[i].width);
x = info[i].x_org + ((info[i].width - mw) / 2);
y = info[i].y_org + ((info[i].height - mh) / 2);
} else {
x = info[i].x_org;
y = info[i].y_org + (topbar ? 0 : info[i].height - mh);
mw = info[i].width;
}
XFree(info);
} else
#endif
{
if (!XGetWindowAttributes(dpy, parentwin, &wa))
die("could not get embedding window attributes: 0x%lx",
parentwin);
if (centered) {
mw = MIN(MAX(max_textw() + promptw, min_width), wa.width);
x = (wa.width - mw) / 2;
y = (wa.height - mh) / 2;
} else {
x = 0;
y = topbar ? 0 : wa.height - mh;
mw = wa.width;
}
}
promptw = (prompt && *prompt) ? TEXTW(prompt) - lrpad / 4 : 0;
inputw = mw / 3; /* input width: ~33% of monitor width */
match();
/* create menu window */
swa.override_redirect = True;
swa.background_pixel = scheme[SchemeNorm][ColBg].pixel;
swa.event_mask = ExposureMask | KeyPressMask | VisibilityChangeMask;
win = XCreateWindow(dpy, parentwin, x, y, mw, mh, border_width,
CopyFromParent, CopyFromParent, CopyFromParent,
CWOverrideRedirect | CWBackPixel | CWEventMask, &swa);
XSetWindowBorder(dpy, win, scheme[SchemeSel][ColBg].pixel);
XSetClassHint(dpy, win, &ch);
/* input methods */
if ((xim = XOpenIM(dpy, NULL, NULL, NULL)) == NULL)
die("XOpenIM failed: could not open input device");
xic = XCreateIC(xim, XNInputStyle, XIMPreeditNothing | XIMStatusNothing,
XNClientWindow, win, XNFocusWindow, win, NULL);
XMapRaised(dpy, win);
if (embed) {
XSelectInput(dpy, parentwin, FocusChangeMask | SubstructureNotifyMask);
if (XQueryTree(dpy, parentwin, &dw, &w, &dws, &du) && dws) {
for (i = 0; i < du && dws[i] != win; ++i)
XSelectInput(dpy, dws[i], FocusChangeMask);
XFree(dws);
}
grabfocus();
}
drw_resize(drw, mw, mh);
drawmenu();
}
static void
usage(void)
{
die("usage: dmenu [-bfiv] [-l lines] [-h height] [-p prompt] [-fn font] [-m monitor]\n"
" [-nb color] [-nf color] [-sb color] [-sf color] [-w windowid]");
}
int
main(int argc, char *argv[])
{
XWindowAttributes wa;
int i, fast = 0;
for (i = 1; i < argc; i++)
/* these options take no arguments */
if (!strcmp(argv[i], "-v")) { /* prints version information */
puts("dmenu-"VERSION);
exit(0);
} else if (!strcmp(argv[i], "-b")) /* appears at the bottom of the screen */
topbar = 0;
else if (!strcmp(argv[i], "-f")) /* grabs keyboard before reading stdin */
fast = 1;
else if (!strcmp(argv[i], "-c")) /* centers dmenu on screen */
centered = 1;
else if (!strcmp(argv[i], "-i")) { /* case-insensitive item matching */
fstrncmp = strncasecmp;
fstrstr = cistrstr;
} else if (i + 1 == argc)
usage();
/* these options take one argument */
else if (!strcmp(argv[i], "-l")) /* number of lines in vertical list */
lines = atoi(argv[++i]);
else if (!strcmp(argv[i], "-h")) { /* minimum height of one menu line */
lineheight = atoi(argv[++i]);
lineheight = MAX(lineheight, min_lineheight);
}
else if (!strcmp(argv[i], "-m"))
mon = atoi(argv[++i]);
else if (!strcmp(argv[i], "-p")) /* adds prompt to left of input field */
prompt = argv[++i];
else if (!strcmp(argv[i], "-fn")) /* font or font set */
fonts[0] = argv[++i];
else if (!strcmp(argv[i], "-nb")) /* normal background color */
colors[SchemeNorm][ColBg] = argv[++i];
else if (!strcmp(argv[i], "-nf")) /* normal foreground color */
colors[SchemeNorm][ColFg] = argv[++i];
else if (!strcmp(argv[i], "-sb")) /* selected background color */
colors[SchemeSel][ColBg] = argv[++i];
else if (!strcmp(argv[i], "-sf")) /* selected foreground color */
colors[SchemeSel][ColFg] = argv[++i];
else if (!strcmp(argv[i], "-w")) /* embedding window id */
embed = argv[++i];
else
usage();
if (!setlocale(LC_CTYPE, "") || !XSupportsLocale())
fputs("warning: no locale support\n", stderr);
if (!(dpy = XOpenDisplay(NULL)))
die("cannot open display");
screen = DefaultScreen(dpy);
root = RootWindow(dpy, screen);
if (!embed || !(parentwin = strtol(embed, NULL, 0)))
parentwin = root;
if (!XGetWindowAttributes(dpy, parentwin, &wa))
die("could not get embedding window attributes: 0x%lx",
parentwin);
drw = drw_create(dpy, screen, root, wa.width, wa.height);
if (!drw_fontset_create(drw, fonts, LENGTH(fonts)))
die("no fonts could be loaded.");
lrpad = drw->fonts->h;
#ifdef __OpenBSD__
if (pledge("stdio rpath", NULL) == -1)
die("pledge");
#endif
if (fast && !isatty(0)) {
grabkeyboard();
readstdin();
} else {
readstdin();
grabkeyboard();
}
setup();
run();
return 1; /* unreachable */
}

@ -0,0 +1,28 @@
--- dmenu.c
+++ dmenu.c
@@ -649,6 +658,7 @@ setup(void)
x = info[i].x_org;
y = info[i].y_org + (topbar ? 0 : info[i].height - mh);
mw = info[i].width;
+
XFree(info);
} else
#endif
@@ -666,11 +676,13 @@ setup(void)
/* create menu window */
swa.override_redirect = True;
- swa.background_pixel = scheme[SchemeNorm][ColBg].pixel;
+ swa.background_pixel = 0;
+ swa.border_pixel = 0;
+ swa.colormap = cmap;
swa.event_mask = ExposureMask | KeyPressMask | VisibilityChangeMask;
- win = XCreateWindow(dpy, parentwin, x, y, mw, mh, 0,
- CopyFromParent, CopyFromParent, CopyFromParent,
- CWOverrideRedirect | CWBackPixel | CWEventMask, &swa);
+ win = XCreateWindow(dpy, parentwin, x, y, mw, mh, border_width,
+ depth, CopyFromParent, visual,
+ CWOverrideRedirect | CWBackPixel | CWBorderPixel | CWColormap | CWEventMask, &swa);
XSetClassHint(dpy, win, &ch);

@ -0,0 +1,13 @@
#!/bin/sh
cachedir="${XDG_CACHE_HOME:-"$HOME/.cache"}"
cache="$cachedir/dmenu_run"
[ ! -e "$cachedir" ] && mkdir -p "$cachedir"
IFS=:
if stest -dqr -n "$cache" $PATH; then
stest -flx $PATH | sort -u | tee "$cache"
else
cat "$cache"
fi

@ -0,0 +1,2 @@
#!/bin/sh
dmenu_path | dmenu "$@" | ${SHELL:-"/bin/sh"} &

@ -0,0 +1,452 @@
/* See LICENSE file for copyright and license details. */
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <X11/Xlib.h>
#include <X11/Xft/Xft.h>
#include "drw.h"
#include "util.h"
#define UTF_INVALID 0xFFFD
#define UTF_SIZ 4
static const unsigned char utfbyte[UTF_SIZ + 1] = {0x80, 0, 0xC0, 0xE0, 0xF0};
static const unsigned char utfmask[UTF_SIZ + 1] = {0xC0, 0x80, 0xE0, 0xF0, 0xF8};
static const long utfmin[UTF_SIZ + 1] = { 0, 0, 0x80, 0x800, 0x10000};
static const long utfmax[UTF_SIZ + 1] = {0x10FFFF, 0x7F, 0x7FF, 0xFFFF, 0x10FFFF};
static long
utf8decodebyte(const char c, size_t *i)
{
for (*i = 0; *i < (UTF_SIZ + 1); ++(*i))
if (((unsigned char)c & utfmask[*i]) == utfbyte[*i])
return (unsigned char)c & ~utfmask[*i];
return 0;
}
static size_t
utf8validate(long *u, size_t i)
{
if (!BETWEEN(*u, utfmin[i], utfmax[i]) || BETWEEN(*u, 0xD800, 0xDFFF))
*u = UTF_INVALID;
for (i = 1; *u > utfmax[i]; ++i)
;
return i;
}
static size_t
utf8decode(const char *c, long *u, size_t clen)
{
size_t i, j, len, type;
long udecoded;
*u = UTF_INVALID;
if (!clen)
return 0;
udecoded = utf8decodebyte(c[0], &len);
if (!BETWEEN(len, 1, UTF_SIZ))
return 1;
for (i = 1, j = 1; i < clen && j < len; ++i, ++j) {
udecoded = (udecoded << 6) | utf8decodebyte(c[i], &type);
if (type)
return j;
}
if (j < len)
return 0;
*u = udecoded;
utf8validate(u, len);
return len;
}
Drw *
drw_create(Display *dpy, int screen, Window root, unsigned int w, unsigned int h, Visual *visual, unsigned int depth, Colormap cmap)
{
Drw *drw = ecalloc(1, sizeof(Drw));
drw->dpy = dpy;
drw->screen = screen;
drw->root = root;
drw->w = w;
drw->h = h;
drw->visual = visual;
drw->depth = depth;
drw->cmap = cmap;
drw->drawable = XCreatePixmap(dpy, root, w, h, depth);
drw->gc = XCreateGC(dpy, drw->drawable, 0, NULL);
XSetLineAttributes(dpy, drw->gc, 1, LineSolid, CapButt, JoinMiter);
return drw;
}
void
drw_resize(Drw *drw, unsigned int w, unsigned int h)
{
if (!drw)
return;
drw->w = w;
drw->h = h;
if (drw->drawable)
XFreePixmap(drw->dpy, drw->drawable);
drw->drawable = XCreatePixmap(drw->dpy, drw->root, w, h, drw->depth);
}
void
drw_free(Drw *drw)
{
XFreePixmap(drw->dpy, drw->drawable);
XFreeGC(drw->dpy, drw->gc);
drw_fontset_free(drw->fonts);
free(drw);
}
/* This function is an implementation detail. Library users should use
* drw_fontset_create instead.
*/
static Fnt *
xfont_create(Drw *drw, const char *fontname, FcPattern *fontpattern)
{
Fnt *font;
XftFont *xfont = NULL;
FcPattern *pattern = NULL;
if (fontname) {
/* Using the pattern found at font->xfont->pattern does not yield the
* same substitution results as using the pattern returned by
* FcNameParse; using the latter results in the desired fallback
* behaviour whereas the former just results in missing-character
* rectangles being drawn, at least with some fonts. */
if (!(xfont = XftFontOpenName(drw->dpy, drw->screen, fontname))) {
fprintf(stderr, "error, cannot load font from name: '%s'\n", fontname);
return NULL;
}
if (!(pattern = FcNameParse((FcChar8 *) fontname))) {
fprintf(stderr, "error, cannot parse font name to pattern: '%s'\n", fontname);
XftFontClose(drw->dpy, xfont);
return NULL;
}
} else if (fontpattern) {
if (!(xfont = XftFontOpenPattern(drw->dpy, fontpattern))) {
fprintf(stderr, "error, cannot load font from pattern.\n");
return NULL;
}
} else {
die("no font specified.");
}
font = ecalloc(1, sizeof(Fnt));
font->xfont = xfont;
font->pattern = pattern;
font->h = xfont->ascent + xfont->descent;
font->dpy = drw->dpy;
return font;
}
static void
xfont_free(Fnt *font)
{
if (!font)
return;
if (font->pattern)
FcPatternDestroy(font->pattern);
XftFontClose(font->dpy, font->xfont);
free(font);
}
Fnt*
drw_fontset_create(Drw* drw, const char *fonts[], size_t fontcount)
{
Fnt *cur, *ret = NULL;
size_t i;
if (!drw || !fonts)
return NULL;
for (i = 1; i <= fontcount; i++) {
if ((cur = xfont_create(drw, fonts[fontcount - i], NULL))) {
cur->next = ret;
ret = cur;
}
}
return (drw->fonts = ret);
}
void
drw_fontset_free(Fnt *font)
{
if (font) {
drw_fontset_free(font->next);
xfont_free(font);
}
}
void
drw_clr_create(Drw *drw, Clr *dest, const char *clrname, unsigned int alpha)
{
if (!drw || !dest || !clrname)
return;
if (!XftColorAllocName(drw->dpy, drw->visual, drw->cmap,
clrname, dest))
die("error, cannot allocate color '%s'", clrname);
dest->pixel = (dest->pixel & 0x00ffffffU) | (alpha << 24);
}
/* Wrapper to create color schemes. The caller has to call free(3) on the
* returned color scheme when done using it. */
Clr *
drw_scm_create(Drw *drw, const char *clrnames[], const unsigned int alphas[], size_t clrcount)
{
size_t i;
Clr *ret;
/* need at least two colors for a scheme */
if (!drw || !clrnames || clrcount < 2 || !(ret = ecalloc(clrcount, sizeof(XftColor))))
return NULL;
for (i = 0; i < clrcount; i++)
drw_clr_create(drw, &ret[i], clrnames[i], alphas[i]);
return ret;
}
void
drw_setfontset(Drw *drw, Fnt *set)
{
if (drw)
drw->fonts = set;
}
void
drw_setscheme(Drw *drw, Clr *scm)
{
if (drw)
drw->scheme = scm;
}
void
drw_rect(Drw *drw, int x, int y, unsigned int w, unsigned int h, int filled, int invert)
{
if (!drw || !drw->scheme)
return;
XSetForeground(drw->dpy, drw->gc, invert ? drw->scheme[ColBg].pixel : drw->scheme[ColFg].pixel);
if (filled)
XFillRectangle(drw->dpy, drw->drawable, drw->gc, x, y, w, h);
else
XDrawRectangle(drw->dpy, drw->drawable, drw->gc, x, y, w - 1, h - 1);
}
int
drw_text(Drw *drw, int x, int y, unsigned int w, unsigned int h, unsigned int lpad, const char *text, int invert)
{
int i, ty, ellipsis_x = 0;
unsigned int tmpw, ew, ellipsis_w = 0, ellipsis_len;
XftDraw *d = NULL;
Fnt *usedfont, *curfont, *nextfont;
int utf8strlen, utf8charlen, render = x || y || w || h;
long utf8codepoint = 0;
const char *utf8str;
FcCharSet *fccharset;
FcPattern *fcpattern;
FcPattern *match;
XftResult result;
int charexists = 0, overflow = 0;
/* keep track of a couple codepoints for which we have no match. */
enum { nomatches_len = 64 };
static struct { long codepoint[nomatches_len]; unsigned int idx; } nomatches;
static unsigned int ellipsis_width = 0;
if (!drw || (render && (!drw->scheme || !w)) || !text || !drw->fonts)
return 0;
if (!render) {
w = invert ? invert : ~invert;
} else {
XSetForeground(drw->dpy, drw->gc, drw->scheme[invert ? ColFg : ColBg].pixel);
XFillRectangle(drw->dpy, drw->drawable, drw->gc, x, y, w, h);
d = XftDrawCreate(drw->dpy, drw->drawable, drw->visual, drw->cmap);
x += lpad;
w -= lpad;
}
usedfont = drw->fonts;
if (!ellipsis_width && render)
ellipsis_width = drw_fontset_getwidth(drw, "...");
while (1) {
ew = ellipsis_len = utf8strlen = 0;
utf8str = text;
nextfont = NULL;
while (*text) {
utf8charlen = utf8decode(text, &utf8codepoint, UTF_SIZ);
for (curfont = drw->fonts; curfont; curfont = curfont->next) {
charexists = charexists || XftCharExists(drw->dpy, curfont->xfont, utf8codepoint);
if (charexists) {
drw_font_getexts(curfont, text, utf8charlen, &tmpw, NULL);
if (ew + ellipsis_width <= w) {
/* keep track where the ellipsis still fits */
ellipsis_x = x + ew;
ellipsis_w = w - ew;
ellipsis_len = utf8strlen;
}
if (ew + tmpw > w) {
overflow = 1;
/* called from drw_fontset_getwidth_clamp():
* it wants the width AFTER the overflow
*/
if (!render)
x += tmpw;
else
utf8strlen = ellipsis_len;
} else if (curfont == usedfont) {
utf8strlen += utf8charlen;
text += utf8charlen;
ew += tmpw;
} else {
nextfont = curfont;
}
break;
}
}
if (overflow || !charexists || nextfont)
break;
else
charexists = 0;
}
if (utf8strlen) {
if (render) {
ty = y + (h - usedfont->h) / 2 + usedfont->xfont->ascent;
XftDrawStringUtf8(d, &drw->scheme[invert ? ColBg : ColFg],
usedfont->xfont, x, ty, (XftChar8 *)utf8str, utf8strlen);
}
x += ew;
w -= ew;
}
if (render && overflow)
drw_text(drw, ellipsis_x, y, ellipsis_w, h, 0, "...", invert);
if (!*text || overflow) {
break;
} else if (nextfont) {
charexists = 0;
usedfont = nextfont;
} else {
/* Regardless of whether or not a fallback font is found, the
* character must be drawn. */
charexists = 1;
for (i = 0; i < nomatches_len; ++i) {
/* avoid calling XftFontMatch if we know we won't find a match */
if (utf8codepoint == nomatches.codepoint[i])
goto no_match;
}
fccharset = FcCharSetCreate();
FcCharSetAddChar(fccharset, utf8codepoint);
if (!drw->fonts->pattern) {
/* Refer to the comment in xfont_create for more information. */
die("the first font in the cache must be loaded from a font string.");
}
fcpattern = FcPatternDuplicate(drw->fonts->pattern);
FcPatternAddCharSet(fcpattern, FC_CHARSET, fccharset);
FcPatternAddBool(fcpattern, FC_SCALABLE, FcTrue);
FcConfigSubstitute(NULL, fcpattern, FcMatchPattern);
FcDefaultSubstitute(fcpattern);
match = XftFontMatch(drw->dpy, drw->screen, fcpattern, &result);
FcCharSetDestroy(fccharset);
FcPatternDestroy(fcpattern);
if (match) {
usedfont = xfont_create(drw, NULL, match);
if (usedfont && XftCharExists(drw->dpy, usedfont->xfont, utf8codepoint)) {
for (curfont = drw->fonts; curfont->next; curfont = curfont->next)
; /* NOP */
curfont->next = usedfont;
} else {
xfont_free(usedfont);
nomatches.codepoint[++nomatches.idx % nomatches_len] = utf8codepoint;
no_match:
usedfont = drw->fonts;
}
}
}
}
if (d)
XftDrawDestroy(d);
return x + (render ? w : 0);
}
void
drw_map(Drw *drw, Window win, int x, int y, unsigned int w, unsigned int h)
{
if (!drw)
return;
XCopyArea(drw->dpy, drw->drawable, win, drw->gc, x, y, w, h, x, y);
XSync(drw->dpy, False);
}
unsigned int
drw_fontset_getwidth(Drw *drw, const char *text)
{
if (!drw || !drw->fonts || !text)
return 0;
return drw_text(drw, 0, 0, 0, 0, 0, text, 0);
}
unsigned int
drw_fontset_getwidth_clamp(Drw *drw, const char *text, unsigned int n)
{
unsigned int tmp = 0;
if (drw && drw->fonts && text && n)
tmp = drw_text(drw, 0, 0, 0, 0, 0, text, n);
return MIN(n, tmp);
}
void
drw_font_getexts(Fnt *font, const char *text, unsigned int len, unsigned int *w, unsigned int *h)
{
XGlyphInfo ext;
if (!font || !text)
return;
XftTextExtentsUtf8(font->dpy, font->xfont, (XftChar8 *)text, len, &ext);
if (w)
*w = ext.xOff;
if (h)
*h = font->h;
}
Cur *
drw_cur_create(Drw *drw, int shape)
{
Cur *cur;
if (!drw || !(cur = ecalloc(1, sizeof(Cur))))
return NULL;
cur->cursor = XCreateFontCursor(drw->dpy, shape);
return cur;
}
void
drw_cur_free(Drw *drw, Cur *cursor)
{
if (!cursor)
return;
XFreeCursor(drw->dpy, cursor->cursor);
free(cursor);
}

@ -0,0 +1,450 @@
/* See LICENSE file for copyright and license details. */
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <X11/Xlib.h>
#include <X11/Xft/Xft.h>
#include "drw.h"
#include "util.h"
#define UTF_INVALID 0xFFFD
#define UTF_SIZ 4
static const unsigned char utfbyte[UTF_SIZ + 1] = {0x80, 0, 0xC0, 0xE0, 0xF0};
static const unsigned char utfmask[UTF_SIZ + 1] = {0xC0, 0x80, 0xE0, 0xF0, 0xF8};
static const long utfmin[UTF_SIZ + 1] = { 0, 0, 0x80, 0x800, 0x10000};
static const long utfmax[UTF_SIZ + 1] = {0x10FFFF, 0x7F, 0x7FF, 0xFFFF, 0x10FFFF};
static long
utf8decodebyte(const char c, size_t *i)
{
for (*i = 0; *i < (UTF_SIZ + 1); ++(*i))
if (((unsigned char)c & utfmask[*i]) == utfbyte[*i])
return (unsigned char)c & ~utfmask[*i];
return 0;
}
static size_t
utf8validate(long *u, size_t i)
{
if (!BETWEEN(*u, utfmin[i], utfmax[i]) || BETWEEN(*u, 0xD800, 0xDFFF))
*u = UTF_INVALID;
for (i = 1; *u > utfmax[i]; ++i)
;
return i;
}
static size_t
utf8decode(const char *c, long *u, size_t clen)
{
size_t i, j, len, type;
long udecoded;
*u = UTF_INVALID;
if (!clen)
return 0;
udecoded = utf8decodebyte(c[0], &len);
if (!BETWEEN(len, 1, UTF_SIZ))
return 1;
for (i = 1, j = 1; i < clen && j < len; ++i, ++j) {
udecoded = (udecoded << 6) | utf8decodebyte(c[i], &type);
if (type)
return j;
}
if (j < len)
return 0;
*u = udecoded;
utf8validate(u, len);
return len;
}
Drw *
drw_create(Display *dpy, int screen, Window root, unsigned int w, unsigned int h)
{
Drw *drw = ecalloc(1, sizeof(Drw));
drw->dpy = dpy;
drw->screen = screen;
drw->root = root;
drw->w = w;
drw->h = h;
drw->drawable = XCreatePixmap(dpy, root, w, h, DefaultDepth(dpy, screen));
drw->gc = XCreateGC(dpy, root, 0, NULL);
XSetLineAttributes(dpy, drw->gc, 1, LineSolid, CapButt, JoinMiter);
return drw;
}
void
drw_resize(Drw *drw, unsigned int w, unsigned int h)
{
if (!drw)
return;
drw->w = w;
drw->h = h;
if (drw->drawable)
XFreePixmap(drw->dpy, drw->drawable);
drw->drawable = XCreatePixmap(drw->dpy, drw->root, w, h, DefaultDepth(drw->dpy, drw->screen));
}
void
drw_free(Drw *drw)
{
XFreePixmap(drw->dpy, drw->drawable);
XFreeGC(drw->dpy, drw->gc);
drw_fontset_free(drw->fonts);
free(drw);
}
/* This function is an implementation detail. Library users should use
* drw_fontset_create instead.
*/
static Fnt *
xfont_create(Drw *drw, const char *fontname, FcPattern *fontpattern)
{
Fnt *font;
XftFont *xfont = NULL;
FcPattern *pattern = NULL;
if (fontname) {
/* Using the pattern found at font->xfont->pattern does not yield the
* same substitution results as using the pattern returned by
* FcNameParse; using the latter results in the desired fallback
* behaviour whereas the former just results in missing-character
* rectangles being drawn, at least with some fonts. */
if (!(xfont = XftFontOpenName(drw->dpy, drw->screen, fontname))) {
fprintf(stderr, "error, cannot load font from name: '%s'\n", fontname);
return NULL;
}
if (!(pattern = FcNameParse((FcChar8 *) fontname))) {
fprintf(stderr, "error, cannot parse font name to pattern: '%s'\n", fontname);
XftFontClose(drw->dpy, xfont);
return NULL;
}
} else if (fontpattern) {
if (!(xfont = XftFontOpenPattern(drw->dpy, fontpattern))) {
fprintf(stderr, "error, cannot load font from pattern.\n");
return NULL;
}
} else {
die("no font specified.");
}
font = ecalloc(1, sizeof(Fnt));
font->xfont = xfont;
font->pattern = pattern;
font->h = xfont->ascent + xfont->descent;
font->dpy = drw->dpy;
return font;
}
static void
xfont_free(Fnt *font)
{
if (!font)
return;
if (font->pattern)
FcPatternDestroy(font->pattern);
XftFontClose(font->dpy, font->xfont);
free(font);
}
Fnt*
drw_fontset_create(Drw* drw, const char *fonts[], size_t fontcount)
{
Fnt *cur, *ret = NULL;
size_t i;
if (!drw || !fonts)
return NULL;
for (i = 1; i <= fontcount; i++) {
if ((cur = xfont_create(drw, fonts[fontcount - i], NULL))) {
cur->next = ret;
ret = cur;
}
}
return (drw->fonts = ret);
}
void
drw_fontset_free(Fnt *font)
{
if (font) {
drw_fontset_free(font->next);
xfont_free(font);
}
}
void
drw_clr_create(Drw *drw, Clr *dest, const char *clrname)
{
if (!drw || !dest || !clrname)
return;
if (!XftColorAllocName(drw->dpy, DefaultVisual(drw->dpy, drw->screen),
DefaultColormap(drw->dpy, drw->screen),
clrname, dest))
die("error, cannot allocate color '%s'", clrname);
}
/* Wrapper to create color schemes. The caller has to call free(3) on the
* returned color scheme when done using it. */
Clr *
drw_scm_create(Drw *drw, const char *clrnames[], size_t clrcount)
{
size_t i;
Clr *ret;
/* need at least two colors for a scheme */
if (!drw || !clrnames || clrcount < 2 || !(ret = ecalloc(clrcount, sizeof(XftColor))))
return NULL;
for (i = 0; i < clrcount; i++)
drw_clr_create(drw, &ret[i], clrnames[i]);
return ret;
}
void
drw_setfontset(Drw *drw, Fnt *set)
{
if (drw)
drw->fonts = set;
}
void
drw_setscheme(Drw *drw, Clr *scm)
{
if (drw)
drw->scheme = scm;
}
void
drw_rect(Drw *drw, int x, int y, unsigned int w, unsigned int h, int filled, int invert)
{
if (!drw || !drw->scheme)
return;
XSetForeground(drw->dpy, drw->gc, invert ? drw->scheme[ColBg].pixel : drw->scheme[ColFg].pixel);
if (filled)
XFillRectangle(drw->dpy, drw->drawable, drw->gc, x, y, w, h);
else
XDrawRectangle(drw->dpy, drw->drawable, drw->gc, x, y, w - 1, h - 1);
}
int
drw_text(Drw *drw, int x, int y, unsigned int w, unsigned int h, unsigned int lpad, const char *text, int invert)
{
int i, ty, ellipsis_x = 0;
unsigned int tmpw, ew, ellipsis_w = 0, ellipsis_len;
XftDraw *d = NULL;
Fnt *usedfont, *curfont, *nextfont;
int utf8strlen, utf8charlen, render = x || y || w || h;
long utf8codepoint = 0;
const char *utf8str;
FcCharSet *fccharset;
FcPattern *fcpattern;
FcPattern *match;
XftResult result;
int charexists = 0, overflow = 0;
/* keep track of a couple codepoints for which we have no match. */
enum { nomatches_len = 64 };
static struct { long codepoint[nomatches_len]; unsigned int idx; } nomatches;
static unsigned int ellipsis_width = 0;
if (!drw || (render && (!drw->scheme || !w)) || !text || !drw->fonts)
return 0;
if (!render) {
w = invert ? invert : ~invert;
} else {
XSetForeground(drw->dpy, drw->gc, drw->scheme[invert ? ColFg : ColBg].pixel);
XFillRectangle(drw->dpy, drw->drawable, drw->gc, x, y, w, h);
d = XftDrawCreate(drw->dpy, drw->drawable,
DefaultVisual(drw->dpy, drw->screen),
DefaultColormap(drw->dpy, drw->screen));
x += lpad;
w -= lpad;
}
usedfont = drw->fonts;
if (!ellipsis_width && render)
ellipsis_width = drw_fontset_getwidth(drw, "...");
while (1) {
ew = ellipsis_len = utf8strlen = 0;
utf8str = text;
nextfont = NULL;
while (*text) {
utf8charlen = utf8decode(text, &utf8codepoint, UTF_SIZ);
for (curfont = drw->fonts; curfont; curfont = curfont->next) {
charexists = charexists || XftCharExists(drw->dpy, curfont->xfont, utf8codepoint);
if (charexists) {
drw_font_getexts(curfont, text, utf8charlen, &tmpw, NULL);
if (ew + ellipsis_width <= w) {
/* keep track where the ellipsis still fits */
ellipsis_x = x + ew;
ellipsis_w = w - ew;
ellipsis_len = utf8strlen;
}
if (ew + tmpw > w) {
overflow = 1;
/* called from drw_fontset_getwidth_clamp():
* it wants the width AFTER the overflow
*/
if (!render)
x += tmpw;
else
utf8strlen = ellipsis_len;
} else if (curfont == usedfont) {
utf8strlen += utf8charlen;
text += utf8charlen;
ew += tmpw;
} else {
nextfont = curfont;
}
break;
}
}
if (overflow || !charexists || nextfont)
break;
else
charexists = 0;
}
if (utf8strlen) {
if (render) {
ty = y + (h - usedfont->h) / 2 + usedfont->xfont->ascent;
XftDrawStringUtf8(d, &drw->scheme[invert ? ColBg : ColFg],
usedfont->xfont, x, ty, (XftChar8 *)utf8str, utf8strlen);
}
x += ew;
w -= ew;
}
if (render && overflow)
drw_text(drw, ellipsis_x, y, ellipsis_w, h, 0, "...", invert);
if (!*text || overflow) {
break;
} else if (nextfont) {
charexists = 0;
usedfont = nextfont;
} else {
/* Regardless of whether or not a fallback font is found, the
* character must be drawn. */
charexists = 1;
for (i = 0; i < nomatches_len; ++i) {
/* avoid calling XftFontMatch if we know we won't find a match */
if (utf8codepoint == nomatches.codepoint[i])
goto no_match;
}
fccharset = FcCharSetCreate();
FcCharSetAddChar(fccharset, utf8codepoint);
if (!drw->fonts->pattern) {
/* Refer to the comment in xfont_create for more information. */
die("the first font in the cache must be loaded from a font string.");
}
fcpattern = FcPatternDuplicate(drw->fonts->pattern);
FcPatternAddCharSet(fcpattern, FC_CHARSET, fccharset);
FcPatternAddBool(fcpattern, FC_SCALABLE, FcTrue);
FcConfigSubstitute(NULL, fcpattern, FcMatchPattern);
FcDefaultSubstitute(fcpattern);
match = XftFontMatch(drw->dpy, drw->screen, fcpattern, &result);
FcCharSetDestroy(fccharset);
FcPatternDestroy(fcpattern);
if (match) {
usedfont = xfont_create(drw, NULL, match);
if (usedfont && XftCharExists(drw->dpy, usedfont->xfont, utf8codepoint)) {
for (curfont = drw->fonts; curfont->next; curfont = curfont->next)
; /* NOP */
curfont->next = usedfont;
} else {
xfont_free(usedfont);
nomatches.codepoint[++nomatches.idx % nomatches_len] = utf8codepoint;
no_match:
usedfont = drw->fonts;
}
}
}
}
if (d)
XftDrawDestroy(d);
return x + (render ? w : 0);
}
void
drw_map(Drw *drw, Window win, int x, int y, unsigned int w, unsigned int h)
{
if (!drw)
return;
XCopyArea(drw->dpy, drw->drawable, win, drw->gc, x, y, w, h, x, y);
XSync(drw->dpy, False);
}
unsigned int
drw_fontset_getwidth(Drw *drw, const char *text)
{
if (!drw || !drw->fonts || !text)
return 0;
return drw_text(drw, 0, 0, 0, 0, 0, text, 0);
}
unsigned int
drw_fontset_getwidth_clamp(Drw *drw, const char *text, unsigned int n)
{
unsigned int tmp = 0;
if (drw && drw->fonts && text && n)
tmp = drw_text(drw, 0, 0, 0, 0, 0, text, n);
return MIN(n, tmp);
}
void
drw_font_getexts(Fnt *font, const char *text, unsigned int len, unsigned int *w, unsigned int *h)
{
XGlyphInfo ext;
if (!font || !text)
return;
XftTextExtentsUtf8(font->dpy, font->xfont, (XftChar8 *)text, len, &ext);
if (w)
*w = ext.xOff;
if (h)
*h = font->h;
}
Cur *
drw_cur_create(Drw *drw, int shape)
{
Cur *cur;
if (!drw || !(cur = ecalloc(1, sizeof(Cur))))
return NULL;
cur->cursor = XCreateFontCursor(drw->dpy, shape);
return cur;
}
void
drw_cur_free(Drw *drw, Cur *cursor)
{
if (!cursor)
return;
XFreeCursor(drw->dpy, cursor->cursor);
free(cursor);
}

@ -0,0 +1,61 @@
/* See LICENSE file for copyright and license details. */
typedef struct {
Cursor cursor;
} Cur;
typedef struct Fnt {
Display *dpy;
unsigned int h;
XftFont *xfont;
FcPattern *pattern;
struct Fnt *next;
} Fnt;
enum { ColFg, ColBg }; /* Clr scheme index */
typedef XftColor Clr;
typedef struct {
unsigned int w, h;
Display *dpy;
int screen;
Window root;
Visual *visual;
unsigned int depth;
Colormap cmap;
Drawable drawable;
GC gc;
Clr *scheme;
Fnt *fonts;
} Drw;
/* Drawable abstraction */
Drw *drw_create(Display *dpy, int screen, Window win, unsigned int w, unsigned int h, Visual*, unsigned int, Colormap);
void drw_resize(Drw *drw, unsigned int w, unsigned int h);
void drw_free(Drw *drw);
/* Fnt abstraction */
Fnt *drw_fontset_create(Drw* drw, const char *fonts[], size_t fontcount);
void drw_fontset_free(Fnt* set);
unsigned int drw_fontset_getwidth(Drw *drw, const char *text);
unsigned int drw_fontset_getwidth_clamp(Drw *drw, const char *text, unsigned int n);
void drw_font_getexts(Fnt *font, const char *text, unsigned int len, unsigned int *w, unsigned int *h);
/* Colorscheme abstraction */
void drw_clr_create(Drw *drw, Clr *dest, const char *clrname, unsigned int alpha);
Clr *drw_scm_create(Drw *drw, const char *clrnames[], const unsigned int alphas[], size_t clrcount);
/* Cursor abstraction */
Cur *drw_cur_create(Drw *drw, int shape);
void drw_cur_free(Drw *drw, Cur *cursor);
/* Drawing context manipulation */
void drw_setfontset(Drw *drw, Fnt *set);
void drw_setscheme(Drw *drw, Clr *scm);
/* Drawing functions */
void drw_rect(Drw *drw, int x, int y, unsigned int w, unsigned int h, int filled, int invert);
int drw_text(Drw *drw, int x, int y, unsigned int w, unsigned int h, unsigned int lpad, const char *text, int invert);
/* Map functions */
void drw_map(Drw *drw, Window win, int x, int y, unsigned int w, unsigned int h);

@ -0,0 +1,58 @@
/* See LICENSE file for copyright and license details. */
typedef struct {
Cursor cursor;
} Cur;
typedef struct Fnt {
Display *dpy;
unsigned int h;
XftFont *xfont;
FcPattern *pattern;
struct Fnt *next;
} Fnt;
enum { ColFg, ColBg }; /* Clr scheme index */
typedef XftColor Clr;
typedef struct {
unsigned int w, h;
Display *dpy;
int screen;
Window root;
Drawable drawable;
GC gc;
Clr *scheme;
Fnt *fonts;
} Drw;
/* Drawable abstraction */
Drw *drw_create(Display *dpy, int screen, Window win, unsigned int w, unsigned int h);
void drw_resize(Drw *drw, unsigned int w, unsigned int h);
void drw_free(Drw *drw);
/* Fnt abstraction */
Fnt *drw_fontset_create(Drw* drw, const char *fonts[], size_t fontcount);
void drw_fontset_free(Fnt* set);
unsigned int drw_fontset_getwidth(Drw *drw, const char *text);
unsigned int drw_fontset_getwidth_clamp(Drw *drw, const char *text, unsigned int n);
void drw_font_getexts(Fnt *font, const char *text, unsigned int len, unsigned int *w, unsigned int *h);
/* Colorscheme abstraction */
void drw_clr_create(Drw *drw, Clr *dest, const char *clrname);
Clr *drw_scm_create(Drw *drw, const char *clrnames[], size_t clrcount);
/* Cursor abstraction */
Cur *drw_cur_create(Drw *drw, int shape);
void drw_cur_free(Drw *drw, Cur *cursor);
/* Drawing context manipulation */
void drw_setfontset(Drw *drw, Fnt *set);
void drw_setscheme(Drw *drw, Clr *scm);
/* Drawing functions */
void drw_rect(Drw *drw, int x, int y, unsigned int w, unsigned int h, int filled, int invert);
int drw_text(Drw *drw, int x, int y, unsigned int w, unsigned int h, unsigned int lpad, const char *text, int invert);
/* Map functions */
void drw_map(Drw *drw, Window win, int x, int y, unsigned int w, unsigned int h);

@ -0,0 +1,9 @@
#!/bin/bash
patch -p1 < dmenu-border-4.9.diff
patch -p1 < dmenu-center-5.2.diff
patch -p1 < dmenu-highlight-4.9.diff
patch -p1 < dmenu-lineheight-5.2.diff
sudo make install

@ -0,0 +1,90 @@
.TH STEST 1 dmenu\-VERSION
.SH NAME
stest \- filter a list of files by properties
.SH SYNOPSIS
.B stest
.RB [ -abcdefghlpqrsuwx ]
.RB [ -n
.IR file ]
.RB [ -o
.IR file ]
.RI [ file ...]
.SH DESCRIPTION
.B stest
takes a list of files and filters by the files' properties, analogous to
.IR test (1).
Files which pass all tests are printed to stdout. If no files are given, stest
reads files from stdin.
.SH OPTIONS
.TP
.B \-a
Test hidden files.
.TP
.B \-b
Test that files are block specials.
.TP
.B \-c
Test that files are character specials.
.TP
.B \-d
Test that files are directories.
.TP
.B \-e
Test that files exist.
.TP
.B \-f
Test that files are regular files.
.TP
.B \-g
Test that files have their set-group-ID flag set.
.TP
.B \-h
Test that files are symbolic links.
.TP
.B \-l
Test the contents of a directory given as an argument.
.TP
.BI \-n " file"
Test that files are newer than
.IR file .
.TP
.BI \-o " file"
Test that files are older than
.IR file .
.TP
.B \-p
Test that files are named pipes.
.TP
.B \-q
No files are printed, only the exit status is returned.
.TP
.B \-r
Test that files are readable.
.TP
.B \-s
Test that files are not empty.
.TP
.B \-u
Test that files have their set-user-ID flag set.
.TP
.B \-v
Invert the sense of tests, only failing files pass.
.TP
.B \-w
Test that files are writable.
.TP
.B \-x
Test that files are executable.
.SH EXIT STATUS
.TP
.B 0
At least one file passed all tests.
.TP
.B 1
No files passed all tests.
.TP
.B 2
An error occurred.
.SH SEE ALSO
.IR dmenu (1),
.IR test (1)

@ -0,0 +1,109 @@
/* See LICENSE file for copyright and license details. */
#include <sys/stat.h>
#include <dirent.h>
#include <limits.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include "arg.h"
char *argv0;
#define FLAG(x) (flag[(x)-'a'])
static void test(const char *, const char *);
static void usage(void);
static int match = 0;
static int flag[26];
static struct stat old, new;
static void
test(const char *path, const char *name)
{
struct stat st, ln;
if ((!stat(path, &st) && (FLAG('a') || name[0] != '.') /* hidden files */
&& (!FLAG('b') || S_ISBLK(st.st_mode)) /* block special */
&& (!FLAG('c') || S_ISCHR(st.st_mode)) /* character special */
&& (!FLAG('d') || S_ISDIR(st.st_mode)) /* directory */
&& (!FLAG('e') || access(path, F_OK) == 0) /* exists */
&& (!FLAG('f') || S_ISREG(st.st_mode)) /* regular file */
&& (!FLAG('g') || st.st_mode & S_ISGID) /* set-group-id flag */
&& (!FLAG('h') || (!lstat(path, &ln) && S_ISLNK(ln.st_mode))) /* symbolic link */
&& (!FLAG('n') || st.st_mtime > new.st_mtime) /* newer than file */
&& (!FLAG('o') || st.st_mtime < old.st_mtime) /* older than file */
&& (!FLAG('p') || S_ISFIFO(st.st_mode)) /* named pipe */
&& (!FLAG('r') || access(path, R_OK) == 0) /* readable */
&& (!FLAG('s') || st.st_size > 0) /* not empty */
&& (!FLAG('u') || st.st_mode & S_ISUID) /* set-user-id flag */
&& (!FLAG('w') || access(path, W_OK) == 0) /* writable */
&& (!FLAG('x') || access(path, X_OK) == 0)) != FLAG('v')) { /* executable */
if (FLAG('q'))
exit(0);
match = 1;
puts(name);
}
}
static void
usage(void)
{
fprintf(stderr, "usage: %s [-abcdefghlpqrsuvwx] "
"[-n file] [-o file] [file...]\n", argv0);
exit(2); /* like test(1) return > 1 on error */
}
int
main(int argc, char *argv[])
{
struct dirent *d;
char path[PATH_MAX], *line = NULL, *file;
size_t linesiz = 0;
ssize_t n;
DIR *dir;
int r;
ARGBEGIN {
case 'n': /* newer than file */
case 'o': /* older than file */
file = EARGF(usage());
if (!(FLAG(ARGC()) = !stat(file, (ARGC() == 'n' ? &new : &old))))
perror(file);
break;
default:
/* miscellaneous operators */
if (strchr("abcdefghlpqrsuvwx", ARGC()))
FLAG(ARGC()) = 1;
else
usage(); /* unknown flag */
} ARGEND;
if (!argc) {
/* read list from stdin */
while ((n = getline(&line, &linesiz, stdin)) > 0) {
if (line[n - 1] == '\n')
line[n - 1] = '\0';
test(line, line);
}
free(line);
} else {
for (; argc; argc--, argv++) {
if (FLAG('l') && (dir = opendir(*argv))) {
/* test directory contents */
while ((d = readdir(dir))) {
r = snprintf(path, sizeof path, "%s/%s",
*argv, d->d_name);
if (r >= 0 && (size_t)r < sizeof path)
test(path, d->d_name);
}
closedir(dir);
} else {
test(*argv, *argv);
}
}
}
return match ? 0 : 1;
}

@ -0,0 +1,36 @@
/* See LICENSE file for copyright and license details. */
#include <stdarg.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "util.h"
void
die(const char *fmt, ...)
{
va_list ap;
va_start(ap, fmt);
vfprintf(stderr, fmt, ap);
va_end(ap);
if (fmt[0] && fmt[strlen(fmt)-1] == ':') {
fputc(' ', stderr);
perror(NULL);
} else {
fputc('\n', stderr);
}
exit(1);
}
void *
ecalloc(size_t nmemb, size_t size)
{
void *p;
if (!(p = calloc(nmemb, size)))
die("calloc:");
return p;
}

@ -0,0 +1,8 @@
/* See LICENSE file for copyright and license details. */
#define MAX(A, B) ((A) > (B) ? (A) : (B))
#define MIN(A, B) ((A) < (B) ? (A) : (B))
#define BETWEEN(X, A, B) ((A) <= (X) && (X) <= (B))
void die(const char *fmt, ...);
void *ecalloc(size_t nmemb, size_t size);

@ -0,0 +1,79 @@
#!/bin/bash
sourceCodePro="https://github.com/adobe-fonts/source-code-pro"
awsomeFont="https://use.fontawesome.com/releases/v6.2.1/fontawesome-free-6.2.1-desktop.zip"
fontsInstallDir="/usr/local/share/fonts"
fonts_intro()
{
color_start "themeInstall"
echo ""
echo "Following Fonts Will be installed"
echo $sourceCodePro
echo $awsomeFont
color_stop
color_start "themeIndication"
if [[ -d "$fontsInstallDir" ]]
then
echo "$fontsInstallDir Exists"
else
echo "$fontsInstallDir Will be created"
sudo mkdir $fontsInstallDir
fi
color_stop
sleep $sleepTime
}
fonts_outro()
{
color_start "themeInstall"
echo "fonts installation complete"
echo ""
color_stop
cd $MAIN_DIR
}
fonts_install_all()
{
cd $MAIN_DIR/programs/fonts/
fonts_intro
git clone $sourceCodePro
color_start "themeIndication"
if [[ -d "$fontsInstallDir/source-code-pro" ]]
then
echo "A version of source-code-pro exits and will be repacled"
sudo rm -r $fontsInstallDir/source-code-pro
else
echo "Creating $fontsInstallDir/source-code-pro directory"
fi
color_stop
sleep $sleepTime
sudo cp -r source-code-pro $fontsInstallDir
sudo chmod -R 555 $fontsInstallDir/source-code-pro
sudo rm -r source-code-pro
wget $awsomeFont
unzip *.zip
rm *.zip
dir=$(find . -mindepth 1 -maxdepth 1 -type d)
color_start "themeIndication"
if [[ -d "$fontsInstallDir/fontawesome" ]]
then
echo "A version of awsomeFont exits and will be repacled"
sudo rm -r $fontsInstallDir/fontawesome
else
echo "Creating $fontsInstallDir/fontawesome directory"
fi
color_stop
sleep $sleepTime
sudo cp -r $dir $fontsInstallDir/fontawesome
sudo chmod -R 555 $fontsInstallDir/fontawesome
rm -r $dir
fc-cache -v
fonts_outro
}

@ -0,0 +1,9 @@
#!/bin/bash
NVIMDIR="/home/$USER/.config/"
CURDATE=$(date +%m%d%Y%H%M%S)
cd $NVIMDIR
rm -rf nvim
rm -rf ~/.local/share/nvim
rm -rf ~/.local/state/nvim

@ -0,0 +1,75 @@
#!/bin/bash
COMMON_SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
package_manager="none"
# arg($1) = Program's name
install_prog()
{
color_start "themeInstall"
echo "--> $1"
echo " |--> Will Be Installed"
echo ""
color_stop
${pckgmngr_list[$OS_NO]} $1
echo "${pckgmngr_list[$OS_NO]} $1"
}
# arg($1) = Program's name
skip_prog()
{
color_start "themeSkip"
echo "--> $1"
echo " |--> Was found and will not be installed"
echo ""
echo "${pckgmngr_list[$OS_NO]} $1"
color_stop
}
install_from_list()
{
theList=("$@")
for i in "${!theList[@]}";
do
currentProg=${theList[$i]}
if [ $( check_installed $currentProg ) -eq 0 ]
then
install_prog $currentProg
else
skip_prog $currentProg
fi
done
}
install_start()
{
graphics_indication "Common installations these programs are OS independent from"
sleep $sleepTime
install_from_list "${common_programs_list[@]}"
graphics_indication "Istallation will begin for $OS"
sleep $sleepTime
case $OS in
debian)
install_from_list "${default_installs_debian[@]}"
install_from_list "${custom_installs_debian[@]}"
;;
arch)
;;
install_from_list "${default_installs_arch[@]}"
install_from_list "${custom_installs_arch[@]}"
rasberry)
;;
install_from_list "${default_installs_raspberry[@]}"
install_from_list "${custom_installs_raspberry[@]}"
*)
echo "Invalid os for installation"
exit_abord
;;
esac
}

@ -0,0 +1,23 @@
#!/bin/bash
source common.sh
LOCALVIMRC="$main_dir/dotfiles/vim/init.vim"
VIMRC="/home/$USER/.vimrc"
VIMDIR="/home/$USER/"
if [ "$OS" == "Debian"]; then
sudo apt install libxext-dev libxcb1-dev libxcb-damage0-dev libxcb-dpms0-dev libxcb-xfixes0-dev libxcb-shape0-dev libxcb-render-util0-dev libxcb-render0-dev libxcb-randr0-dev libxcb-composite0-dev libxcb-image0-dev libxcb-present-dev libxcb-xinerama0-dev libxcb-glx0-dev libpixman-1-dev libdbus-1-dev libconfig-dev libgl-dev libegl-dev libpcre2-dev libevdev-dev uthash-dev libev-dev libx11-xcb-dev meson libpcre++-dev
git clone --single-branch --branch next-rebase --depth=1 https://github.com/ibhagwan/picom
cd picom
meson setup --buildtype=release . build
sudo ninja -C build install
fi
if [ "$OS" == "Arch"]; then
sudo pacman -S picom
fi

@ -0,0 +1,5 @@
#!/bin/bash
source common.sh
sudo $installCMD sddm
systemctl enable sddm

File diff suppressed because it is too large Load Diff

@ -0,0 +1,336 @@
/*
* Intel ACPI Component Architecture
* AML/ASL+ Disassembler version 20220331 (64-bit version)
* Copyright (c) 2000 - 2022 Intel Corporation
*
* Disassembly of apic.dat, Thu Sep 1 23:24:17 2022
*
* ACPI Data Table [APIC]
*
* Format: [HexOffset DecimalOffset ByteLength] FieldName : FieldValue (in hex)
*/
[000h 0000 4] Signature : "APIC" [Multiple APIC Description Table (MADT)]
[004h 0004 4] Table Length : 00000138
[008h 0008 1] Revision : 03
[009h 0009 1] Checksum : 2C
[00Ah 0010 6] Oem ID : "LENOVO"
[010h 0016 8] Oem Table ID : "CB-01 "
[018h 0024 4] Oem Revision : 00000001
[01Ch 0028 4] Asl Compiler ID : "ACPI"
[020h 0032 4] Asl Compiler Revision : 00040000
[024h 0036 4] Local Apic Address : FEE00000
[028h 0040 4] Flags (decoded below) : 00000001
PC-AT Compatibility : 1
[02Ch 0044 1] Subtable Type : 00 [Processor Local APIC]
[02Dh 0045 1] Length : 08
[02Eh 0046 1] Processor ID : 00
[02Fh 0047 1] Local Apic ID : 00
[030h 0048 4] Flags (decoded below) : 00000001
Processor Enabled : 1
Runtime Online Capable : 0
[034h 0052 1] Subtable Type : 00 [Processor Local APIC]
[035h 0053 1] Length : 08
[036h 0054 1] Processor ID : 01
[037h 0055 1] Local Apic ID : 01
[038h 0056 4] Flags (decoded below) : 00000001
Processor Enabled : 1
Runtime Online Capable : 0
[03Ch 0060 1] Subtable Type : 00 [Processor Local APIC]
[03Dh 0061 1] Length : 08
[03Eh 0062 1] Processor ID : 02
[03Fh 0063 1] Local Apic ID : 02
[040h 0064 4] Flags (decoded below) : 00000001
Processor Enabled : 1
Runtime Online Capable : 0
[044h 0068 1] Subtable Type : 00 [Processor Local APIC]
[045h 0069 1] Length : 08
[046h 0070 1] Processor ID : 03
[047h 0071 1] Local Apic ID : 03
[048h 0072 4] Flags (decoded below) : 00000001
Processor Enabled : 1
Runtime Online Capable : 0
[04Ch 0076 1] Subtable Type : 00 [Processor Local APIC]
[04Dh 0077 1] Length : 08
[04Eh 0078 1] Processor ID : 04
[04Fh 0079 1] Local Apic ID : 04
[050h 0080 4] Flags (decoded below) : 00000001
Processor Enabled : 1
Runtime Online Capable : 0
[054h 0084 1] Subtable Type : 00 [Processor Local APIC]
[055h 0085 1] Length : 08
[056h 0086 1] Processor ID : 05
[057h 0087 1] Local Apic ID : 05
[058h 0088 4] Flags (decoded below) : 00000001
Processor Enabled : 1
Runtime Online Capable : 0
[05Ch 0092 1] Subtable Type : 00 [Processor Local APIC]
[05Dh 0093 1] Length : 08
[05Eh 0094 1] Processor ID : 06
[05Fh 0095 1] Local Apic ID : 06
[060h 0096 4] Flags (decoded below) : 00000001
Processor Enabled : 1
Runtime Online Capable : 0
[064h 0100 1] Subtable Type : 00 [Processor Local APIC]
[065h 0101 1] Length : 08
[066h 0102 1] Processor ID : 07
[067h 0103 1] Local Apic ID : 07
[068h 0104 4] Flags (decoded below) : 00000001
Processor Enabled : 1
Runtime Online Capable : 0
[06Ch 0108 1] Subtable Type : 00 [Processor Local APIC]
[06Dh 0109 1] Length : 08
[06Eh 0110 1] Processor ID : 08
[06Fh 0111 1] Local Apic ID : 08
[070h 0112 4] Flags (decoded below) : 00000001
Processor Enabled : 1
Runtime Online Capable : 0
[074h 0116 1] Subtable Type : 00 [Processor Local APIC]
[075h 0117 1] Length : 08
[076h 0118 1] Processor ID : 09
[077h 0119 1] Local Apic ID : 09
[078h 0120 4] Flags (decoded below) : 00000001
Processor Enabled : 1
Runtime Online Capable : 0
[07Ch 0124 1] Subtable Type : 00 [Processor Local APIC]
[07Dh 0125 1] Length : 08
[07Eh 0126 1] Processor ID : 0A
[07Fh 0127 1] Local Apic ID : 0A
[080h 0128 4] Flags (decoded below) : 00000001
Processor Enabled : 1
Runtime Online Capable : 0
[084h 0132 1] Subtable Type : 00 [Processor Local APIC]
[085h 0133 1] Length : 08
[086h 0134 1] Processor ID : 0B
[087h 0135 1] Local Apic ID : 0B
[088h 0136 4] Flags (decoded below) : 00000001
Processor Enabled : 1
Runtime Online Capable : 0
[08Ch 0140 1] Subtable Type : 00 [Processor Local APIC]
[08Dh 0141 1] Length : 08
[08Eh 0142 1] Processor ID : 0C
[08Fh 0143 1] Local Apic ID : 0C
[090h 0144 4] Flags (decoded below) : 00000001
Processor Enabled : 1
Runtime Online Capable : 0
[094h 0148 1] Subtable Type : 00 [Processor Local APIC]
[095h 0149 1] Length : 08
[096h 0150 1] Processor ID : 0D
[097h 0151 1] Local Apic ID : 0D
[098h 0152 4] Flags (decoded below) : 00000001
Processor Enabled : 1
Runtime Online Capable : 0
[09Ch 0156 1] Subtable Type : 00 [Processor Local APIC]
[09Dh 0157 1] Length : 08
[09Eh 0158 1] Processor ID : 0E
[09Fh 0159 1] Local Apic ID : 0E
[0A0h 0160 4] Flags (decoded below) : 00000001
Processor Enabled : 1
Runtime Online Capable : 0
[0A4h 0164 1] Subtable Type : 00 [Processor Local APIC]
[0A5h 0165 1] Length : 08
[0A6h 0166 1] Processor ID : 0F
[0A7h 0167 1] Local Apic ID : 0F
[0A8h 0168 4] Flags (decoded below) : 00000001
Processor Enabled : 1
Runtime Online Capable : 0
[0ACh 0172 1] Subtable Type : 01 [I/O APIC]
[0ADh 0173 1] Length : 0C
[0AEh 0174 1] I/O Apic ID : 21
[0AFh 0175 1] Reserved : 00
[0B0h 0176 4] Address : FEC00000
[0B4h 0180 4] Interrupt : 00000000
[0B8h 0184 1] Subtable Type : 01 [I/O APIC]
[0B9h 0185 1] Length : 0C
[0BAh 0186 1] I/O Apic ID : 22
[0BBh 0187 1] Reserved : 00
[0BCh 0188 4] Address : FEC01000
[0C0h 0192 4] Interrupt : 00000018
[0C4h 0196 1] Subtable Type : 02 [Interrupt Source Override]
[0C5h 0197 1] Length : 0A
[0C6h 0198 1] Bus : 00
[0C7h 0199 1] Source : 00
[0C8h 0200 4] Interrupt : 00000002
[0CCh 0204 2] Flags (decoded below) : 0000
Polarity : 0
Trigger Mode : 0
[0CEh 0206 1] Subtable Type : 02 [Interrupt Source Override]
[0CFh 0207 1] Length : 0A
[0D0h 0208 1] Bus : 00
[0D1h 0209 1] Source : 09
[0D2h 0210 4] Interrupt : 00000009
[0D6h 0214 2] Flags (decoded below) : 000F
Polarity : 3
Trigger Mode : 3
[0D8h 0216 1] Subtable Type : 04 [Local APIC NMI]
[0D9h 0217 1] Length : 06
[0DAh 0218 1] Processor ID : 00
[0DBh 0219 2] Flags (decoded below) : 0005
Polarity : 1
Trigger Mode : 1
[0DDh 0221 1] Interrupt Input LINT : 01
[0DEh 0222 1] Subtable Type : 04 [Local APIC NMI]
[0DFh 0223 1] Length : 06
[0E0h 0224 1] Processor ID : 01
[0E1h 0225 2] Flags (decoded below) : 0005
Polarity : 1
Trigger Mode : 1
[0E3h 0227 1] Interrupt Input LINT : 01
[0E4h 0228 1] Subtable Type : 04 [Local APIC NMI]
[0E5h 0229 1] Length : 06
[0E6h 0230 1] Processor ID : 02
[0E7h 0231 2] Flags (decoded below) : 0005
Polarity : 1
Trigger Mode : 1
[0E9h 0233 1] Interrupt Input LINT : 01
[0EAh 0234 1] Subtable Type : 04 [Local APIC NMI]
[0EBh 0235 1] Length : 06
[0ECh 0236 1] Processor ID : 03
[0EDh 0237 2] Flags (decoded below) : 0005
Polarity : 1
Trigger Mode : 1
[0EFh 0239 1] Interrupt Input LINT : 01
[0F0h 0240 1] Subtable Type : 04 [Local APIC NMI]
[0F1h 0241 1] Length : 06
[0F2h 0242 1] Processor ID : 04
[0F3h 0243 2] Flags (decoded below) : 0005
Polarity : 1
Trigger Mode : 1
[0F5h 0245 1] Interrupt Input LINT : 01
[0F6h 0246 1] Subtable Type : 04 [Local APIC NMI]
[0F7h 0247 1] Length : 06
[0F8h 0248 1] Processor ID : 05
[0F9h 0249 2] Flags (decoded below) : 0005
Polarity : 1
Trigger Mode : 1
[0FBh 0251 1] Interrupt Input LINT : 01
[0FCh 0252 1] Subtable Type : 04 [Local APIC NMI]
[0FDh 0253 1] Length : 06
[0FEh 0254 1] Processor ID : 06
[0FFh 0255 2] Flags (decoded below) : 0005
Polarity : 1
Trigger Mode : 1
[101h 0257 1] Interrupt Input LINT : 01
[102h 0258 1] Subtable Type : 04 [Local APIC NMI]
[103h 0259 1] Length : 06
[104h 0260 1] Processor ID : 07
[105h 0261 2] Flags (decoded below) : 0005
Polarity : 1
Trigger Mode : 1
[107h 0263 1] Interrupt Input LINT : 01
[108h 0264 1] Subtable Type : 04 [Local APIC NMI]
[109h 0265 1] Length : 06
[10Ah 0266 1] Processor ID : 08
[10Bh 0267 2] Flags (decoded below) : 0005
Polarity : 1
Trigger Mode : 1
[10Dh 0269 1] Interrupt Input LINT : 01
[10Eh 0270 1] Subtable Type : 04 [Local APIC NMI]
[10Fh 0271 1] Length : 06
[110h 0272 1] Processor ID : 09
[111h 0273 2] Flags (decoded below) : 0005
Polarity : 1
Trigger Mode : 1
[113h 0275 1] Interrupt Input LINT : 01
[114h 0276 1] Subtable Type : 04 [Local APIC NMI]
[115h 0277 1] Length : 06
[116h 0278 1] Processor ID : 0A
[117h 0279 2] Flags (decoded below) : 0005
Polarity : 1
Trigger Mode : 1
[119h 0281 1] Interrupt Input LINT : 01
[11Ah 0282 1] Subtable Type : 04 [Local APIC NMI]
[11Bh 0283 1] Length : 06
[11Ch 0284 1] Processor ID : 0B
[11Dh 0285 2] Flags (decoded below) : 0005
Polarity : 1
Trigger Mode : 1
[11Fh 0287 1] Interrupt Input LINT : 01
[120h 0288 1] Subtable Type : 04 [Local APIC NMI]
[121h 0289 1] Length : 06
[122h 0290 1] Processor ID : 0C
[123h 0291 2] Flags (decoded below) : 0005
Polarity : 1
Trigger Mode : 1
[125h 0293 1] Interrupt Input LINT : 01
[126h 0294 1] Subtable Type : 04 [Local APIC NMI]
[127h 0295 1] Length : 06
[128h 0296 1] Processor ID : 0D
[129h 0297 2] Flags (decoded below) : 0005
Polarity : 1
Trigger Mode : 1
[12Bh 0299 1] Interrupt Input LINT : 01
[12Ch 0300 1] Subtable Type : 04 [Local APIC NMI]
[12Dh 0301 1] Length : 06
[12Eh 0302 1] Processor ID : 0E
[12Fh 0303 2] Flags (decoded below) : 0005
Polarity : 1
Trigger Mode : 1
[131h 0305 1] Interrupt Input LINT : 01
[132h 0306 1] Subtable Type : 04 [Local APIC NMI]
[133h 0307 1] Length : 06
[134h 0308 1] Processor ID : 0F
[135h 0309 2] Flags (decoded below) : 0005
Polarity : 1
Trigger Mode : 1
[137h 0311 1] Interrupt Input LINT : 01
Raw Table Data: Length 312 (0x138)
0000: 41 50 49 43 38 01 00 00 03 2C 4C 45 4E 4F 56 4F // APIC8....,LENOVO
0010: 43 42 2D 30 31 20 20 20 01 00 00 00 41 43 50 49 // CB-01 ....ACPI
0020: 00 00 04 00 00 00 E0 FE 01 00 00 00 00 08 00 00 // ................
0030: 01 00 00 00 00 08 01 01 01 00 00 00 00 08 02 02 // ................
0040: 01 00 00 00 00 08 03 03 01 00 00 00 00 08 04 04 // ................
0050: 01 00 00 00 00 08 05 05 01 00 00 00 00 08 06 06 // ................
0060: 01 00 00 00 00 08 07 07 01 00 00 00 00 08 08 08 // ................
0070: 01 00 00 00 00 08 09 09 01 00 00 00 00 08 0A 0A // ................
0080: 01 00 00 00 00 08 0B 0B 01 00 00 00 00 08 0C 0C // ................
0090: 01 00 00 00 00 08 0D 0D 01 00 00 00 00 08 0E 0E // ................
00A0: 01 00 00 00 00 08 0F 0F 01 00 00 00 01 0C 21 00 // ..............!.
00B0: 00 00 C0 FE 00 00 00 00 01 0C 22 00 00 10 C0 FE // ..........".....
00C0: 18 00 00 00 02 0A 00 00 02 00 00 00 00 00 02 0A // ................
00D0: 00 09 09 00 00 00 0F 00 04 06 00 05 00 01 04 06 // ................
00E0: 01 05 00 01 04 06 02 05 00 01 04 06 03 05 00 01 // ................
00F0: 04 06 04 05 00 01 04 06 05 05 00 01 04 06 06 05 // ................
0100: 00 01 04 06 07 05 00 01 04 06 08 05 00 01 04 06 // ................
0110: 09 05 00 01 04 06 0A 05 00 01 04 06 0B 05 00 01 // ................
0120: 04 06 0C 05 00 01 04 06 0D 05 00 01 04 06 0E 05 // ................
0130: 00 01 04 06 0F 05 00 01 // ........

@ -0,0 +1,138 @@
/*
* Intel ACPI Component Architecture
* AML/ASL+ Disassembler version 20220331 (64-bit version)
* Copyright (c) 2000 - 2022 Intel Corporation
*
* Disassembly of asf!.dat, Thu Sep 1 23:24:17 2022
*
* ACPI Data Table [ASF!]
*
* Format: [HexOffset DecimalOffset ByteLength] FieldName : FieldValue (in hex)
*/
[000h 0000 4] Signature : "ASF!" [Alert Standard Format Table]
[004h 0004 4] Table Length : 000000A5
[008h 0008 1] Revision : 20
[009h 0009 1] Checksum : 0B
[00Ah 0010 6] Oem ID : "LENOVO"
[010h 0016 8] Oem Table ID : "CB-01 "
[018h 0024 4] Oem Revision : 00000001
[01Ch 0028 4] Asl Compiler ID : "ACPI"
[020h 0032 4] Asl Compiler Revision : 00040000
[024h 0036 1] Subtable Type : 00 [ASF Information]
[025h 0037 1] Reserved : 00
[026h 0038 2] Length : 0010
[028h 0040 1] Minimum Reset Value : 00
[029h 0041 1] Minimum Polling Interval : FF
[02Ah 0042 2] System ID : 0001
[02Ch 0044 4] Manufacturer ID : 57010000
[030h 0048 1] Flags : 00
[031h 0049 3] Reserved : 000000
[034h 0052 1] Subtable Type : 01 [ASF Alerts]
[035h 0053 1] Reserved : 00
[036h 0054 2] Length : 002C
[038h 0056 1] AssertMask : 00
[039h 0057 1] DeassertMask : 00
[03Ah 0058 1] Alert Count : 03
[03Bh 0059 1] Alert Data Length : 0C
[03Ch 0060 1] Address : 80
[03Dh 0061 1] Command : 23
[03Eh 0062 1] Mask : 01
[03Fh 0063 1] Value : 01
[040h 0064 1] SensorType : 01
[041h 0065 1] Type : 01
[042h 0066 1] Offset : 00
[043h 0067 1] SourceType : 39
[044h 0068 1] Severity : 10
[045h 0069 1] SensorNumber : 00
[046h 0070 1] Entity : 07
[047h 0071 1] Instance : 00
[048h 0072 1] Address : 80
[049h 0073 1] Command : 23
[04Ah 0074 1] Mask : 02
[04Bh 0075 1] Value : 02
[04Ch 0076 1] SensorType : 01
[04Dh 0077 1] Type : 01
[04Eh 0078 1] Offset : 00
[04Fh 0079 1] SourceType : 39
[050h 0080 1] Severity : 10
[051h 0081 1] SensorNumber : 01
[052h 0082 1] Entity : 07
[053h 0083 1] Instance : 00
[054h 0084 1] Address : 80
[055h 0085 1] Command : 23
[056h 0086 1] Mask : 04
[057h 0087 1] Value : 04
[058h 0088 1] SensorType : 01
[059h 0089 1] Type : 01
[05Ah 0090 1] Offset : 00
[05Bh 0091 1] SourceType : 39
[05Ch 0092 1] Severity : 10
[05Dh 0093 1] SensorNumber : 02
[05Eh 0094 1] Entity : 07
[05Fh 0095 1] Instance : 00
[060h 0096 1] Subtable Type : 02 [ASF Remote Control]
[061h 0097 1] Reserved : 00
[062h 0098 2] Length : 0018
[064h 0100 1] Control Count : 04
[065h 0101 1] Control Data Length : 04
[066h 0102 2] Reserved : 0000
[068h 0104 1] Function : 00
[069h 0105 1] Address : A9
[06Ah 0106 1] Command : 50
[06Bh 0107 1] Value : 00
[06Ch 0108 1] Function : 01
[06Dh 0109 1] Address : A9
[06Eh 0110 1] Command : 52
[06Fh 0111 1] Value : 00
[070h 0112 1] Function : 02
[071h 0113 1] Address : A9
[072h 0114 1] Command : 51
[073h 0115 1] Value : 00
[074h 0116 1] Function : 03
[075h 0117 1] Address : A9
[076h 0118 1] Command : 53
[077h 0119 1] Value : 00
[078h 0120 1] Subtable Type : 03 [ASF RMCP Boot Options]
[079h 0121 1] Reserved : 00
[07Ah 0122 2] Length : 0017
[07Ch 0124 7] Capabilities : 21 F8 00 00 00 1B F0
[083h 0131 1] Completion Code : 00
[084h 0132 4] Enterprise ID : 57010000
[088h 0136 1] Command : 00
[089h 0137 2] Parameter : 0000
[08Bh 0139 2] Boot Options : 0001
[08Dh 0141 2] Oem Parameters : 0000
[08Fh 0143 1] Subtable Type : 84 [ASF Address]
[090h 0144 1] Reserved : 00
[091h 0145 2] Length : 0016
[093h 0147 1] Eprom Address : 00
[094h 0148 1] Device Count : 10
[095h 0149 1] Addresses : A0 A2 A4 00 00 00 00 00 00 00 00 00 00 00 00 00
Raw Table Data: Length 165 (0xA5)
0000: 41 53 46 21 A5 00 00 00 20 0B 4C 45 4E 4F 56 4F // ASF!.... .LENOVO
0010: 43 42 2D 30 31 20 20 20 01 00 00 00 41 43 50 49 // CB-01 ....ACPI
0020: 00 00 04 00 00 00 10 00 00 FF 01 00 00 00 01 57 // ...............W
0030: 00 00 00 00 01 00 2C 00 00 00 03 0C 80 23 01 01 // ......,......#..
0040: 01 01 00 39 10 00 07 00 80 23 02 02 01 01 00 39 // ...9.....#.....9
0050: 10 01 07 00 80 23 04 04 01 01 00 39 10 02 07 00 // .....#.....9....
0060: 02 00 18 00 04 04 00 00 00 A9 50 00 01 A9 52 00 // ..........P...R.
0070: 02 A9 51 00 03 A9 53 00 03 00 17 00 21 F8 00 00 // ..Q...S.....!...
0080: 00 1B F0 00 00 00 01 57 00 00 00 01 00 00 00 84 // .......W........
0090: 00 16 00 00 10 A0 A2 A4 00 00 00 00 00 00 00 00 // ................
00A0: 00 00 00 00 00 // .....

@ -0,0 +1,37 @@
/*
* Intel ACPI Component Architecture
* AML/ASL+ Disassembler version 20220331 (64-bit version)
* Copyright (c) 2000 - 2022 Intel Corporation
*
* Disassembly of bgrt.dat, Thu Sep 1 23:24:17 2022
*
* ACPI Data Table [BGRT]
*
* Format: [HexOffset DecimalOffset ByteLength] FieldName : FieldValue (in hex)
*/
[000h 0000 4] Signature : "BGRT" [Boot Graphics Resource Table]
[004h 0004 4] Table Length : 00000038
[008h 0008 1] Revision : 01
[009h 0009 1] Checksum : 37
[00Ah 0010 6] Oem ID : "LENOVO"
[010h 0016 8] Oem Table ID : "CB-01 "
[018h 0024 4] Oem Revision : 00000001
[01Ch 0028 4] Asl Compiler ID : "ACPI"
[020h 0032 4] Asl Compiler Revision : 00040000
[024h 0036 2] Version : 0001
[026h 0038 1] Status (decoded below) : 00
Displayed : 0
Orientation Offset : 0
[027h 0039 1] Image Type : 00
[028h 0040 8] Image Address : 000000006AE4B000
[030h 0048 4] Image OffsetX : 00000399
[034h 0052 4] Image OffsetY : 0000015D
Raw Table Data: Length 56 (0x38)
0000: 42 47 52 54 38 00 00 00 01 37 4C 45 4E 4F 56 4F // BGRT8....7LENOVO
0010: 43 42 2D 30 31 20 20 20 01 00 00 00 41 43 50 49 // CB-01 ....ACPI
0020: 00 00 04 00 01 00 00 00 00 B0 E4 6A 00 00 00 00 // ...........j....
0030: 99 03 00 00 5D 01 00 00 // ....]...

@ -0,0 +1,30 @@
/*
* Intel ACPI Component Architecture
* AML/ASL+ Disassembler version 20220331 (64-bit version)
* Copyright (c) 2000 - 2022 Intel Corporation
*
* Disassembly of boot.dat, Thu Sep 1 23:24:17 2022
*
* ACPI Data Table [BOOT]
*
* Format: [HexOffset DecimalOffset ByteLength] FieldName : FieldValue (in hex)
*/
[000h 0000 4] Signature : "BOOT" [Simple Boot Flag Table]
[004h 0004 4] Table Length : 00000028
[008h 0008 1] Revision : 01
[009h 0009 1] Checksum : F7
[00Ah 0010 6] Oem ID : "LENOVO"
[010h 0016 8] Oem Table ID : "CB-01 "
[018h 0024 4] Oem Revision : 00000001
[01Ch 0028 4] Asl Compiler ID : "ACPI"
[020h 0032 4] Asl Compiler Revision : 00040000
[024h 0036 1] Boot Register Index : 44
[025h 0037 3] Reserved : 000000
Raw Table Data: Length 40 (0x28)
0000: 42 4F 4F 54 28 00 00 00 01 F7 4C 45 4E 4F 56 4F // BOOT(.....LENOVO
0010: 43 42 2D 30 31 20 20 20 01 00 00 00 41 43 50 49 // CB-01 ....ACPI
0020: 00 00 04 00 44 00 00 00 // ....D...

@ -0,0 +1,31 @@
/*
* Intel ACPI Component Architecture
* AML/ASL+ Disassembler version 20220331 (64-bit version)
* Copyright (c) 2000 - 2022 Intel Corporation
*
* Disassembly of cdit.dat, Thu Sep 1 23:24:17 2022
*
* ACPI Data Table [CDIT]
*
* Format: [HexOffset DecimalOffset ByteLength] FieldName : FieldValue (in hex)
*/
[000h 0000 4] Signature : "CDIT"
[004h 0004 4] Table Length : 00000029
[008h 0008 1] Revision : 01
[009h 0009 1] Checksum : 3F
[00Ah 0010 6] Oem ID : "LENOVO"
[010h 0016 8] Oem Table ID : "CB-01 "
[018h 0024 4] Oem Revision : 00000001
[01Ch 0028 4] Asl Compiler ID : "ACPI"
[020h 0032 4] Asl Compiler Revision : 00040000
**** Unknown ACPI table signature [CDIT]
Raw Table Data: Length 41 (0x29)
0000: 43 44 49 54 29 00 00 00 01 3F 4C 45 4E 4F 56 4F // CDIT)....?LENOVO
0010: 43 42 2D 30 31 20 20 20 01 00 00 00 41 43 50 49 // CB-01 ....ACPI
0020: 00 00 04 00 01 00 00 00 0A // .........

@ -0,0 +1,267 @@
/*
* Intel ACPI Component Architecture
* AML/ASL+ Disassembler version 20220331 (64-bit version)
* Copyright (c) 2000 - 2022 Intel Corporation
*
* Disassembly of crat.dat, Thu Sep 1 23:24:17 2022
*
* ACPI Data Table [CRAT]
*
* Format: [HexOffset DecimalOffset ByteLength] FieldName : FieldValue (in hex)
*/
[000h 0000 4] Signature : "CRAT"
[004h 0004 4] Table Length : 00000EE8
[008h 0008 1] Revision : 01
[009h 0009 1] Checksum : ED
[00Ah 0010 6] Oem ID : "LENOVO"
[010h 0016 8] Oem Table ID : "CB-01 "
[018h 0024 4] Oem Revision : 00000001
[01Ch 0028 4] Asl Compiler ID : "ACPI"
[020h 0032 4] Asl Compiler Revision : 00040000
**** Unknown ACPI table signature [CRAT]
Raw Table Data: Length 3816 (0xEE8)
0000: 43 52 41 54 E8 0E 00 00 01 ED 4C 45 4E 4F 56 4F // CRAT......LENOVO
0010: 43 42 2D 30 31 20 20 20 01 00 00 00 41 43 50 49 // CB-01 ....ACPI
0020: 00 00 04 00 3C 00 00 00 00 00 00 00 00 00 00 00 // ....<...........
0030: 01 28 00 00 01 00 00 00 00 00 00 00 00 00 00 00 // .(..............
0040: 00 00 00 00 00 00 0A 00 00 00 00 00 40 00 00 00 // ............@...
0050: 00 00 00 00 00 00 00 00 01 28 00 00 01 00 00 00 // .........(......
0060: 00 00 00 00 00 00 0C 00 00 00 00 00 00 00 F4 7F // ................
0070: 00 00 00 00 40 00 00 00 00 00 00 00 00 00 00 00 // ....@...........
0080: 01 28 00 00 01 00 00 00 00 00 00 00 00 00 00 00 // .(..............
0090: 01 00 00 00 00 00 00 80 07 00 00 00 40 00 00 00 // ............@...
00A0: 00 00 00 00 00 00 00 00 02 40 00 00 0B 00 00 00 // .........@......
00B0: 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 00 // ................
00C0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
00D0: 00 00 00 00 20 00 00 00 01 01 40 00 08 00 01 00 // .... .....@.....
00E0: 00 00 00 00 00 00 00 00 02 40 00 00 0D 00 00 00 // .........@......
00F0: 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 00 // ................
0100: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0110: 00 00 00 00 20 00 00 00 01 01 40 00 08 00 01 00 // .... .....@.....
0120: 00 00 00 00 00 00 00 00 02 40 00 00 0F 00 00 00 // .........@......
0130: 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 00 // ................
0140: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0150: 00 00 00 00 00 02 00 00 02 01 40 00 08 02 01 00 // ..........@.....
0160: 00 00 00 00 00 00 00 00 02 40 00 00 0F 00 00 00 // .........@......
0170: 00 00 00 00 FF 00 00 00 00 00 00 00 00 00 00 00 // ................
0180: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0190: 00 00 00 00 00 40 00 00 03 01 40 00 10 00 01 00 // .....@....@.....
01A0: 00 00 00 00 00 00 00 00 02 40 00 00 0B 00 00 00 // .........@......
01B0: 02 00 00 00 0C 00 00 00 00 00 00 00 00 00 00 00 // ................
01C0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
01D0: 00 00 00 00 20 00 00 00 01 01 40 00 08 00 01 00 // .... .....@.....
01E0: 00 00 00 00 00 00 00 00 02 40 00 00 0D 00 00 00 // .........@......
01F0: 02 00 00 00 0C 00 00 00 00 00 00 00 00 00 00 00 // ................
0200: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0210: 00 00 00 00 20 00 00 00 01 01 40 00 08 00 01 00 // .... .....@.....
0220: 00 00 00 00 00 00 00 00 02 40 00 00 0F 00 00 00 // .........@......
0230: 02 00 00 00 0C 00 00 00 00 00 00 00 00 00 00 00 // ................
0240: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0250: 00 00 00 00 00 02 00 00 02 01 40 00 08 02 01 00 // ..........@.....
0260: 00 00 00 00 00 00 00 00 02 40 00 00 0B 00 00 00 // .........@......
0270: 04 00 00 00 30 00 00 00 00 00 00 00 00 00 00 00 // ....0...........
0280: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0290: 00 00 00 00 20 00 00 00 01 01 40 00 08 00 01 00 // .... .....@.....
02A0: 00 00 00 00 00 00 00 00 02 40 00 00 0D 00 00 00 // .........@......
02B0: 04 00 00 00 30 00 00 00 00 00 00 00 00 00 00 00 // ....0...........
02C0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
02D0: 00 00 00 00 20 00 00 00 01 01 40 00 08 00 01 00 // .... .....@.....
02E0: 00 00 00 00 00 00 00 00 02 40 00 00 0F 00 00 00 // .........@......
02F0: 04 00 00 00 30 00 00 00 00 00 00 00 00 00 00 00 // ....0...........
0300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0310: 00 00 00 00 00 02 00 00 02 01 40 00 08 02 01 00 // ..........@.....
0320: 00 00 00 00 00 00 00 00 02 40 00 00 0B 00 00 00 // .........@......
0330: 06 00 00 00 C0 00 00 00 00 00 00 00 00 00 00 00 // ................
0340: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0350: 00 00 00 00 20 00 00 00 01 01 40 00 08 00 01 00 // .... .....@.....
0360: 00 00 00 00 00 00 00 00 02 40 00 00 0D 00 00 00 // .........@......
0370: 06 00 00 00 C0 00 00 00 00 00 00 00 00 00 00 00 // ................
0380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0390: 00 00 00 00 20 00 00 00 01 01 40 00 08 00 01 00 // .... .....@.....
03A0: 00 00 00 00 00 00 00 00 02 40 00 00 0F 00 00 00 // .........@......
03B0: 06 00 00 00 C0 00 00 00 00 00 00 00 00 00 00 00 // ................
03C0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
03D0: 00 00 00 00 00 02 00 00 02 01 40 00 08 02 01 00 // ..........@.....
03E0: 00 00 00 00 00 00 00 00 02 40 00 00 0B 00 00 00 // .........@......
03F0: 08 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 // ................
0400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0410: 00 00 00 00 20 00 00 00 01 01 40 00 08 00 01 00 // .... .....@.....
0420: 00 00 00 00 00 00 00 00 02 40 00 00 0D 00 00 00 // .........@......
0430: 08 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 // ................
0440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0450: 00 00 00 00 20 00 00 00 01 01 40 00 08 00 01 00 // .... .....@.....
0460: 00 00 00 00 00 00 00 00 02 40 00 00 0F 00 00 00 // .........@......
0470: 08 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 // ................
0480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0490: 00 00 00 00 00 02 00 00 02 01 40 00 08 02 01 00 // ..........@.....
04A0: 00 00 00 00 00 00 00 00 02 40 00 00 0B 00 00 00 // .........@......
04B0: 0A 00 00 00 00 0C 00 00 00 00 00 00 00 00 00 00 // ................
04C0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
04D0: 00 00 00 00 20 00 00 00 01 01 40 00 08 00 01 00 // .... .....@.....
04E0: 00 00 00 00 00 00 00 00 02 40 00 00 0D 00 00 00 // .........@......
04F0: 0A 00 00 00 00 0C 00 00 00 00 00 00 00 00 00 00 // ................
0500: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0510: 00 00 00 00 20 00 00 00 01 01 40 00 08 00 01 00 // .... .....@.....
0520: 00 00 00 00 00 00 00 00 02 40 00 00 0F 00 00 00 // .........@......
0530: 0A 00 00 00 00 0C 00 00 00 00 00 00 00 00 00 00 // ................
0540: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0550: 00 00 00 00 00 02 00 00 02 01 40 00 08 02 01 00 // ..........@.....
0560: 00 00 00 00 00 00 00 00 02 40 00 00 0B 00 00 00 // .........@......
0570: 0C 00 00 00 00 30 00 00 00 00 00 00 00 00 00 00 // .....0..........
0580: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0590: 00 00 00 00 20 00 00 00 01 01 40 00 08 00 01 00 // .... .....@.....
05A0: 00 00 00 00 00 00 00 00 02 40 00 00 0D 00 00 00 // .........@......
05B0: 0C 00 00 00 00 30 00 00 00 00 00 00 00 00 00 00 // .....0..........
05C0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
05D0: 00 00 00 00 20 00 00 00 01 01 40 00 08 00 01 00 // .... .....@.....
05E0: 00 00 00 00 00 00 00 00 02 40 00 00 0F 00 00 00 // .........@......
05F0: 0C 00 00 00 00 30 00 00 00 00 00 00 00 00 00 00 // .....0..........
0600: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0610: 00 00 00 00 00 02 00 00 02 01 40 00 08 02 01 00 // ..........@.....
0620: 00 00 00 00 00 00 00 00 02 40 00 00 0B 00 00 00 // .........@......
0630: 0E 00 00 00 00 C0 00 00 00 00 00 00 00 00 00 00 // ................
0640: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0650: 00 00 00 00 20 00 00 00 01 01 40 00 08 00 01 00 // .... .....@.....
0660: 00 00 00 00 00 00 00 00 02 40 00 00 0D 00 00 00 // .........@......
0670: 0E 00 00 00 00 C0 00 00 00 00 00 00 00 00 00 00 // ................
0680: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0690: 00 00 00 00 20 00 00 00 01 01 40 00 08 00 01 00 // .... .....@.....
06A0: 00 00 00 00 00 00 00 00 02 40 00 00 0F 00 00 00 // .........@......
06B0: 0E 00 00 00 00 C0 00 00 00 00 00 00 00 00 00 00 // ................
06C0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
06D0: 00 00 00 00 00 02 00 00 02 01 40 00 08 02 01 00 // ..........@.....
06E0: 00 00 00 00 00 00 00 00 03 40 00 00 0B 00 00 00 // .........@......
06F0: 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 00 // ................
0700: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0710: 00 00 00 00 01 00 00 00 FF 40 00 00 FF 40 00 00 // .........@...@..
0720: 0F 40 00 00 00 00 00 00 03 40 00 00 0D 00 00 00 // .@.......@......
0730: 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 00 // ................
0740: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0750: 00 00 00 00 01 00 00 00 00 00 FF 40 00 00 FF 40 // ...........@...@
0760: 00 00 0F 40 00 00 00 00 03 40 00 00 AB 00 00 00 // ...@.....@......
0770: 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 00 // ................
0780: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0790: 00 00 00 00 02 00 00 00 04 08 00 00 08 08 00 00 // ................
07A0: FF 40 00 00 00 00 00 00 03 40 00 00 AD 00 00 00 // .@.......@......
07B0: 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 00 // ................
07C0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
07D0: 00 00 00 00 02 00 00 00 00 00 02 02 00 00 04 02 // ................
07E0: 00 00 00 00 00 00 00 00 03 40 00 00 0B 00 00 00 // .........@......
07F0: 02 00 00 00 0C 00 00 00 00 00 00 00 00 00 00 00 // ................
0800: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0810: 00 00 00 00 01 00 00 00 FF 40 00 00 FF 40 00 00 // .........@...@..
0820: 0F 40 00 00 00 00 00 00 03 40 00 00 0D 00 00 00 // .@.......@......
0830: 02 00 00 00 0C 00 00 00 00 00 00 00 00 00 00 00 // ................
0840: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0850: 00 00 00 00 01 00 00 00 00 00 FF 40 00 00 FF 40 // ...........@...@
0860: 00 00 0F 40 00 00 00 00 03 40 00 00 AB 00 00 00 // ...@.....@......
0870: 02 00 00 00 0C 00 00 00 00 00 00 00 00 00 00 00 // ................
0880: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0890: 00 00 00 00 02 00 00 00 04 08 00 00 08 08 00 00 // ................
08A0: FF 40 00 00 00 00 00 00 03 40 00 00 AD 00 00 00 // .@.......@......
08B0: 02 00 00 00 0C 00 00 00 00 00 00 00 00 00 00 00 // ................
08C0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
08D0: 00 00 00 00 02 00 00 00 00 00 02 02 00 00 04 02 // ................
08E0: 00 00 00 00 00 00 00 00 03 40 00 00 0B 00 00 00 // .........@......
08F0: 04 00 00 00 30 00 00 00 00 00 00 00 00 00 00 00 // ....0...........
0900: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0910: 00 00 00 00 01 00 00 00 FF 40 00 00 FF 40 00 00 // .........@...@..
0920: 0F 40 00 00 00 00 00 00 03 40 00 00 0D 00 00 00 // .@.......@......
0930: 04 00 00 00 30 00 00 00 00 00 00 00 00 00 00 00 // ....0...........
0940: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0950: 00 00 00 00 01 00 00 00 00 00 FF 40 00 00 FF 40 // ...........@...@
0960: 00 00 0F 40 00 00 00 00 03 40 00 00 AB 00 00 00 // ...@.....@......
0970: 04 00 00 00 30 00 00 00 00 00 00 00 00 00 00 00 // ....0...........
0980: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0990: 00 00 00 00 02 00 00 00 04 08 00 00 08 08 00 00 // ................
09A0: FF 40 00 00 00 00 00 00 03 40 00 00 AD 00 00 00 // .@.......@......
09B0: 04 00 00 00 30 00 00 00 00 00 00 00 00 00 00 00 // ....0...........
09C0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
09D0: 00 00 00 00 02 00 00 00 00 00 02 02 00 00 04 02 // ................
09E0: 00 00 00 00 00 00 00 00 03 40 00 00 0B 00 00 00 // .........@......
09F0: 06 00 00 00 C0 00 00 00 00 00 00 00 00 00 00 00 // ................
0A00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0A10: 00 00 00 00 01 00 00 00 FF 40 00 00 FF 40 00 00 // .........@...@..
0A20: 0F 40 00 00 00 00 00 00 03 40 00 00 0D 00 00 00 // .@.......@......
0A30: 06 00 00 00 C0 00 00 00 00 00 00 00 00 00 00 00 // ................
0A40: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0A50: 00 00 00 00 01 00 00 00 00 00 FF 40 00 00 FF 40 // ...........@...@
0A60: 00 00 0F 40 00 00 00 00 03 40 00 00 AB 00 00 00 // ...@.....@......
0A70: 06 00 00 00 C0 00 00 00 00 00 00 00 00 00 00 00 // ................
0A80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0A90: 00 00 00 00 02 00 00 00 04 08 00 00 08 08 00 00 // ................
0AA0: FF 40 00 00 00 00 00 00 03 40 00 00 AD 00 00 00 // .@.......@......
0AB0: 06 00 00 00 C0 00 00 00 00 00 00 00 00 00 00 00 // ................
0AC0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0AD0: 00 00 00 00 02 00 00 00 00 00 02 02 00 00 04 02 // ................
0AE0: 00 00 00 00 00 00 00 00 03 40 00 00 0B 00 00 00 // .........@......
0AF0: 08 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 // ................
0B00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0B10: 00 00 00 00 01 00 00 00 FF 40 00 00 FF 40 00 00 // .........@...@..
0B20: 0F 40 00 00 00 00 00 00 03 40 00 00 0D 00 00 00 // .@.......@......
0B30: 08 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 // ................
0B40: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0B50: 00 00 00 00 01 00 00 00 00 00 FF 40 00 00 FF 40 // ...........@...@
0B60: 00 00 0F 40 00 00 00 00 03 40 00 00 AB 00 00 00 // ...@.....@......
0B70: 08 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 // ................
0B80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0B90: 00 00 00 00 02 00 00 00 04 08 00 00 08 08 00 00 // ................
0BA0: FF 40 00 00 00 00 00 00 03 40 00 00 AD 00 00 00 // .@.......@......
0BB0: 08 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 // ................
0BC0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0BD0: 00 00 00 00 02 00 00 00 00 00 02 02 00 00 04 02 // ................
0BE0: 00 00 00 00 00 00 00 00 03 40 00 00 0B 00 00 00 // .........@......
0BF0: 0A 00 00 00 00 0C 00 00 00 00 00 00 00 00 00 00 // ................
0C00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0C10: 00 00 00 00 01 00 00 00 FF 40 00 00 FF 40 00 00 // .........@...@..
0C20: 0F 40 00 00 00 00 00 00 03 40 00 00 0D 00 00 00 // .@.......@......
0C30: 0A 00 00 00 00 0C 00 00 00 00 00 00 00 00 00 00 // ................
0C40: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0C50: 00 00 00 00 01 00 00 00 00 00 FF 40 00 00 FF 40 // ...........@...@
0C60: 00 00 0F 40 00 00 00 00 03 40 00 00 AB 00 00 00 // ...@.....@......
0C70: 0A 00 00 00 00 0C 00 00 00 00 00 00 00 00 00 00 // ................
0C80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0C90: 00 00 00 00 02 00 00 00 04 08 00 00 08 08 00 00 // ................
0CA0: FF 40 00 00 00 00 00 00 03 40 00 00 AD 00 00 00 // .@.......@......
0CB0: 0A 00 00 00 00 0C 00 00 00 00 00 00 00 00 00 00 // ................
0CC0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0CD0: 00 00 00 00 02 00 00 00 00 00 02 02 00 00 04 02 // ................
0CE0: 00 00 00 00 00 00 00 00 03 40 00 00 0B 00 00 00 // .........@......
0CF0: 0C 00 00 00 00 30 00 00 00 00 00 00 00 00 00 00 // .....0..........
0D00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0D10: 00 00 00 00 01 00 00 00 FF 40 00 00 FF 40 00 00 // .........@...@..
0D20: 0F 40 00 00 00 00 00 00 03 40 00 00 0D 00 00 00 // .@.......@......
0D30: 0C 00 00 00 00 30 00 00 00 00 00 00 00 00 00 00 // .....0..........
0D40: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0D50: 00 00 00 00 01 00 00 00 00 00 FF 40 00 00 FF 40 // ...........@...@
0D60: 00 00 0F 40 00 00 00 00 03 40 00 00 AB 00 00 00 // ...@.....@......
0D70: 0C 00 00 00 00 30 00 00 00 00 00 00 00 00 00 00 // .....0..........
0D80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0D90: 00 00 00 00 02 00 00 00 04 08 00 00 08 08 00 00 // ................
0DA0: FF 40 00 00 00 00 00 00 03 40 00 00 AD 00 00 00 // .@.......@......
0DB0: 0C 00 00 00 00 30 00 00 00 00 00 00 00 00 00 00 // .....0..........
0DC0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0DD0: 00 00 00 00 02 00 00 00 00 00 02 02 00 00 04 02 // ................
0DE0: 00 00 00 00 00 00 00 00 03 40 00 00 0B 00 00 00 // .........@......
0DF0: 0E 00 00 00 00 C0 00 00 00 00 00 00 00 00 00 00 // ................
0E00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0E10: 00 00 00 00 01 00 00 00 FF 40 00 00 FF 40 00 00 // .........@...@..
0E20: 0F 40 00 00 00 00 00 00 03 40 00 00 0D 00 00 00 // .@.......@......
0E30: 0E 00 00 00 00 C0 00 00 00 00 00 00 00 00 00 00 // ................
0E40: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0E50: 00 00 00 00 01 00 00 00 00 00 FF 40 00 00 FF 40 // ...........@...@
0E60: 00 00 0F 40 00 00 00 00 03 40 00 00 AB 00 00 00 // ...@.....@......
0E70: 0E 00 00 00 00 C0 00 00 00 00 00 00 00 00 00 00 // ................
0E80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0E90: 00 00 00 00 02 00 00 00 04 08 00 00 08 08 00 00 // ................
0EA0: FF 40 00 00 00 00 00 00 03 40 00 00 AD 00 00 00 // .@.......@......
0EB0: 0E 00 00 00 00 C0 00 00 00 00 00 00 00 00 00 00 // ................
0EC0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0ED0: 00 00 00 00 02 00 00 00 00 00 02 02 00 00 04 02 // ................
0EE0: 00 00 00 00 00 00 00 00 // ........

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

@ -0,0 +1,196 @@
/*
* Intel ACPI Component Architecture
* AML/ASL+ Disassembler version 20220331 (64-bit version)
* Copyright (c) 2000 - 2022 Intel Corporation
*
* Disassembly of facp.dat, Thu Sep 1 23:24:17 2022
*
* ACPI Data Table [FACP]
*
* Format: [HexOffset DecimalOffset ByteLength] FieldName : FieldValue (in hex)
*/
[000h 0000 4] Signature : "FACP" [Fixed ACPI Description Table (FADT)]
[004h 0004 4] Table Length : 0000010C
[008h 0008 1] Revision : 05
[009h 0009 1] Checksum : 5F
[00Ah 0010 6] Oem ID : "LENOVO"
[010h 0016 8] Oem Table ID : "CB-01 "
[018h 0024 4] Oem Revision : 00000001
[01Ch 0028 4] Asl Compiler ID : "ACPI"
[020h 0032 4] Asl Compiler Revision : 00040000
[024h 0036 4] FACS Address : 7AEB2000
[028h 0040 4] DSDT Address : 7AFD5000
[02Ch 0044 1] Model : 00
[02Dh 0045 1] PM Profile : 02 [Mobile]
[02Eh 0046 2] SCI Interrupt : 0009
[030h 0048 4] SMI Command Port : 000000B0
[034h 0052 1] ACPI Enable Value : A0
[035h 0053 1] ACPI Disable Value : A1
[036h 0054 1] S4BIOS Command : 00
[037h 0055 1] P-State Control : 00
[038h 0056 4] PM1A Event Block Address : 00000400
[03Ch 0060 4] PM1B Event Block Address : 00000000
[040h 0064 4] PM1A Control Block Address : 00000404
[044h 0068 4] PM1B Control Block Address : 00000000
[048h 0072 4] PM2 Control Block Address : 00000800
[04Ch 0076 4] PM Timer Block Address : 00000408
[050h 0080 4] GPE0 Block Address : 00000420
[054h 0084 4] GPE1 Block Address : 00000000
[058h 0088 1] PM1 Event Block Length : 04
[059h 0089 1] PM1 Control Block Length : 02
[05Ah 0090 1] PM2 Control Block Length : 01
[05Bh 0091 1] PM Timer Block Length : 04
[05Ch 0092 1] GPE0 Block Length : 08
[05Dh 0093 1] GPE1 Block Length : 00
[05Eh 0094 1] GPE1 Base Offset : 00
[05Fh 0095 1] _CST Support : 00
[060h 0096 2] C2 Latency : 0064
[062h 0098 2] C3 Latency : 03E9
[064h 0100 2] CPU Cache Size : 0000
[066h 0102 2] Cache Flush Stride : 0000
[068h 0104 1] Duty Cycle Offset : 01
[069h 0105 1] Duty Cycle Width : 03
[06Ah 0106 1] RTC Day Alarm Index : 0D
[06Bh 0107 1] RTC Month Alarm Index : 00
[06Ch 0108 1] RTC Century Index : 00
[06Dh 0109 2] Boot Flags (decoded below) : 0003
Legacy Devices Supported (V2) : 1
8042 Present on ports 60/64 (V2) : 1
VGA Not Present (V4) : 0
MSI Not Supported (V4) : 0
PCIe ASPM Not Supported (V4) : 0
CMOS RTC Not Present (V5) : 0
[06Fh 0111 1] Reserved : 00
[070h 0112 4] Flags (decoded below) : 0020C5BD
WBINVD instruction is operational (V1) : 1
WBINVD flushes all caches (V1) : 0
All CPUs support C1 (V1) : 1
C2 works on MP system (V1) : 1
Control Method Power Button (V1) : 1
Control Method Sleep Button (V1) : 1
RTC wake not in fixed reg space (V1) : 0
RTC can wake system from S4 (V1) : 1
32-bit PM Timer (V1) : 1
Docking Supported (V1) : 0
Reset Register Supported (V2) : 1
Sealed Case (V3) : 0
Headless - No Video (V3) : 0
Use native instr after SLP_TYPx (V3) : 0
PCIEXP_WAK Bits Supported (V4) : 1
Use Platform Timer (V4) : 1
RTC_STS valid on S4 wake (V4) : 0
Remote Power-on capable (V4) : 0
Use APIC Cluster Model (V4) : 0
Use APIC Physical Destination Mode (V4) : 0
Hardware Reduced (V5) : 0
Low Power S0 Idle (V5) : 1
[074h 0116 12] Reset Register : [Generic Address Structure]
[074h 0116 1] Space ID : 01 [SystemIO]
[075h 0117 1] Bit Width : 08
[076h 0118 1] Bit Offset : 00
[077h 0119 1] Encoded Access Width : 01 [Byte Access:8]
[078h 0120 8] Address : 00000000000000B0
[080h 0128 1] Value to cause reset : FB
[081h 0129 2] ARM Flags (decoded below) : 0000
PSCI Compliant : 0
Must use HVC for PSCI : 0
[083h 0131 1] FADT Minor Revision : 00
[084h 0132 8] FACS Address : 0000000000000000
[08Ch 0140 8] DSDT Address : 000000007AFD5000
[094h 0148 12] PM1A Event Block : [Generic Address Structure]
[094h 0148 1] Space ID : 01 [SystemIO]
[095h 0149 1] Bit Width : 20
[096h 0150 1] Bit Offset : 00
[097h 0151 1] Encoded Access Width : 03 [DWord Access:32]
[098h 0152 8] Address : 0000000000000400
[0A0h 0160 12] PM1B Event Block : [Generic Address Structure]
[0A0h 0160 1] Space ID : 00 [SystemMemory]
[0A1h 0161 1] Bit Width : 00
[0A2h 0162 1] Bit Offset : 00
[0A3h 0163 1] Encoded Access Width : 00 [Undefined/Legacy]
[0A4h 0164 8] Address : 0000000000000000
[0ACh 0172 12] PM1A Control Block : [Generic Address Structure]
[0ACh 0172 1] Space ID : 01 [SystemIO]
[0ADh 0173 1] Bit Width : 10
[0AEh 0174 1] Bit Offset : 00
[0AFh 0175 1] Encoded Access Width : 02 [Word Access:16]
[0B0h 0176 8] Address : 0000000000000404
[0B8h 0184 12] PM1B Control Block : [Generic Address Structure]
[0B8h 0184 1] Space ID : 00 [SystemMemory]
[0B9h 0185 1] Bit Width : 00
[0BAh 0186 1] Bit Offset : 00
[0BBh 0187 1] Encoded Access Width : 00 [Undefined/Legacy]
[0BCh 0188 8] Address : 0000000000000000
[0C4h 0196 12] PM2 Control Block : [Generic Address Structure]
[0C4h 0196 1] Space ID : 01 [SystemIO]
[0C5h 0197 1] Bit Width : 08
[0C6h 0198 1] Bit Offset : 00
[0C7h 0199 1] Encoded Access Width : 01 [Byte Access:8]
[0C8h 0200 8] Address : 0000000000000800
[0D0h 0208 12] PM Timer Block : [Generic Address Structure]
[0D0h 0208 1] Space ID : 01 [SystemIO]
[0D1h 0209 1] Bit Width : 20
[0D2h 0210 1] Bit Offset : 00
[0D3h 0211 1] Encoded Access Width : 03 [DWord Access:32]
[0D4h 0212 8] Address : 0000000000000408
[0DCh 0220 12] GPE0 Block : [Generic Address Structure]
[0DCh 0220 1] Space ID : 01 [SystemIO]
[0DDh 0221 1] Bit Width : 40
[0DEh 0222 1] Bit Offset : 00
[0DFh 0223 1] Encoded Access Width : 01 [Byte Access:8]
[0E0h 0224 8] Address : 0000000000000420
[0E8h 0232 12] GPE1 Block : [Generic Address Structure]
[0E8h 0232 1] Space ID : 00 [SystemMemory]
[0E9h 0233 1] Bit Width : 00
[0EAh 0234 1] Bit Offset : 00
[0EBh 0235 1] Encoded Access Width : 01 [Byte Access:8]
[0ECh 0236 8] Address : 0000000000000000
[0F4h 0244 12] Sleep Control Register : [Generic Address Structure]
[0F4h 0244 1] Space ID : 00 [SystemMemory]
[0F5h 0245 1] Bit Width : 00
[0F6h 0246 1] Bit Offset : 00
[0F7h 0247 1] Encoded Access Width : 00 [Undefined/Legacy]
[0F8h 0248 8] Address : 0000000000000000
[100h 0256 12] Sleep Status Register : [Generic Address Structure]
[100h 0256 1] Space ID : 00 [SystemMemory]
[101h 0257 1] Bit Width : 00
[102h 0258 1] Bit Offset : 00
[103h 0259 1] Encoded Access Width : 00 [Undefined/Legacy]
[104h 0260 8] Address : 0000000000000000
/**** ACPI table terminates in the middle of a data structure! (dump table) */
Raw Table Data: Length 268 (0x10C)
0000: 46 41 43 50 0C 01 00 00 05 5F 4C 45 4E 4F 56 4F // FACP....._LENOVO
0010: 43 42 2D 30 31 20 20 20 01 00 00 00 41 43 50 49 // CB-01 ....ACPI
0020: 00 00 04 00 00 20 EB 7A 00 50 FD 7A 00 02 09 00 // ..... .z.P.z....
0030: B0 00 00 00 A0 A1 00 00 00 04 00 00 00 00 00 00 // ................
0040: 04 04 00 00 00 00 00 00 00 08 00 00 08 04 00 00 // ................
0050: 20 04 00 00 00 00 00 00 04 02 01 04 08 00 00 00 // ...............
0060: 64 00 E9 03 00 00 00 00 01 03 0D 00 00 03 00 00 // d...............
0070: BD C5 20 00 01 08 00 01 B0 00 00 00 00 00 00 00 // .. .............
0080: FB 00 00 00 00 00 00 00 00 00 00 00 00 50 FD 7A // .............P.z
0090: 00 00 00 00 01 20 00 03 00 04 00 00 00 00 00 00 // ..... ..........
00A0: 00 00 00 00 00 00 00 00 00 00 00 00 01 10 00 02 // ................
00B0: 04 04 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
00C0: 00 00 00 00 01 08 00 01 00 08 00 00 00 00 00 00 // ................
00D0: 01 20 00 03 08 04 00 00 00 00 00 00 01 40 00 01 // . ...........@..
00E0: 20 04 00 00 00 00 00 00 00 00 00 01 00 00 00 00 // ...............
00F0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0100: 00 00 00 00 00 00 00 00 00 00 00 00 // ............

@ -0,0 +1,32 @@
/*
* Intel ACPI Component Architecture
* AML/ASL+ Disassembler version 20220331 (64-bit version)
* Copyright (c) 2000 - 2022 Intel Corporation
*
* Disassembly of facs.dat, Thu Sep 1 23:24:17 2022
*
* ACPI Data Table [FACS]
*
* Format: [HexOffset DecimalOffset ByteLength] FieldName : FieldValue (in hex)
*/
[000h 0000 4] Signature : "FACS"
[004h 0004 4] Length : 00000040
[008h 0008 4] Hardware Signature : 0A7D3EDC
[00Ch 0012 4] 32 Firmware Waking Vector : 00000000
[010h 0016 4] Global Lock : 00000000
[014h 0020 4] Flags (decoded below) : 00000000
S4BIOS Support Present : 0
64-bit Wake Supported (V2) : 0
[018h 0024 8] 64 Firmware Waking Vector : 0000000000000000
[020h 0032 1] Version : 02
[021h 0033 3] Reserved : 000000
[024h 0036 4] OspmFlags (decoded below) : 00000000
64-bit Wake Env Required (V2) : 0
Raw Table Data: Length 64 (0x40)
0000: 46 41 43 53 40 00 00 00 DC 3E 7D 0A 00 00 00 00 // FACS@....>}.....
0010: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0020: 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0030: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................

@ -0,0 +1,42 @@
/*
* Intel ACPI Component Architecture
* AML/ASL+ Disassembler version 20220331 (64-bit version)
* Copyright (c) 2000 - 2022 Intel Corporation
*
* Disassembly of fpdt.dat, Thu Sep 1 23:24:17 2022
*
* ACPI Data Table [FPDT]
*
* Format: [HexOffset DecimalOffset ByteLength] FieldName : FieldValue (in hex)
*/
[000h 0000 4] Signature : "FPDT" [Firmware Performance Data Table]
[004h 0004 4] Table Length : 00000044
[008h 0008 1] Revision : 01
[009h 0009 1] Checksum : 41
[00Ah 0010 6] Oem ID : "LENOVO"
[010h 0016 8] Oem Table ID : "CB-01 "
[018h 0024 4] Oem Revision : 00000001
[01Ch 0028 4] Asl Compiler ID : "ACPI"
[020h 0032 4] Asl Compiler Revision : 00040000
[024h 0036 2] Subtable Type : 0000
[026h 0038 1] Length : 10
[027h 0039 1] Revision : 01
[028h 0040 4] Reserved : 00000000
[02Ch 0044 8] FPDT Boot Record Address : 0000000071F80000
[034h 0052 2] Subtable Type : 0001
[036h 0054 1] Length : 10
[037h 0055 1] Revision : 01
[038h 0056 4] Reserved : 00000000
[03Ch 0060 8] S3PT Record Address : 0000000071F7F000
Raw Table Data: Length 68 (0x44)
0000: 46 50 44 54 44 00 00 00 01 41 4C 45 4E 4F 56 4F // FPDTD....ALENOVO
0010: 43 42 2D 30 31 20 20 20 01 00 00 00 41 43 50 49 // CB-01 ....ACPI
0020: 00 00 04 00 00 00 10 01 00 00 00 00 00 00 F8 71 // ...............q
0030: 00 00 00 00 01 00 10 01 00 00 00 00 00 F0 F7 71 // ...............q
0040: 00 00 00 00 // ....

@ -0,0 +1,43 @@
/*
* Intel ACPI Component Architecture
* AML/ASL+ Disassembler version 20220331 (64-bit version)
* Copyright (c) 2000 - 2022 Intel Corporation
*
* Disassembly of hpet.dat, Thu Sep 1 23:24:17 2022
*
* ACPI Data Table [HPET]
*
* Format: [HexOffset DecimalOffset ByteLength] FieldName : FieldValue (in hex)
*/
[000h 0000 4] Signature : "HPET" [High Precision Event Timer Table]
[004h 0004 4] Table Length : 00000038
[008h 0008 1] Revision : 01
[009h 0009 1] Checksum : 1C
[00Ah 0010 6] Oem ID : "LENOVO"
[010h 0016 8] Oem Table ID : "CB-01 "
[018h 0024 4] Oem Revision : 00000001
[01Ch 0028 4] Asl Compiler ID : "ACPI"
[020h 0032 4] Asl Compiler Revision : 00040000
[024h 0036 4] Hardware Block ID : 10228210
[028h 0040 12] Timer Block Register : [Generic Address Structure]
[028h 0040 1] Space ID : 00 [SystemMemory]
[029h 0041 1] Bit Width : 00
[02Ah 0042 1] Bit Offset : 00
[02Bh 0043 1] Encoded Access Width : 00 [Undefined/Legacy]
[02Ch 0044 8] Address : 00000000FED00000
[034h 0052 1] Sequence Number : 00
[035h 0053 2] Minimum Clock Ticks : 0080
[037h 0055 1] Flags (decoded below) : 00
4K Page Protect : 0
64K Page Protect : 0
Raw Table Data: Length 56 (0x38)
0000: 48 50 45 54 38 00 00 00 01 1C 4C 45 4E 4F 56 4F // HPET8.....LENOVO
0010: 43 42 2D 30 31 20 20 20 01 00 00 00 41 43 50 49 // CB-01 ....ACPI
0020: 00 00 04 00 10 82 22 10 00 00 00 00 00 00 D0 FE // ......".........
0030: 00 00 00 00 00 80 00 00 // ........

@ -0,0 +1,476 @@
/*
* Intel ACPI Component Architecture
* AML/ASL+ Disassembler version 20220331 (64-bit version)
* Copyright (c) 2000 - 2022 Intel Corporation
*
* Disassembly of ivrs.dat, Thu Sep 1 23:24:17 2022
*
* ACPI Data Table [IVRS]
*
* Format: [HexOffset DecimalOffset ByteLength] FieldName : FieldValue (in hex)
*/
[000h 0000 4] Signature : "IVRS" [I/O Virtualization Reporting Structure]
[004h 0004 4] Table Length : 000001A4
[008h 0008 1] Revision : 02
[009h 0009 1] Checksum : 64
[00Ah 0010 6] Oem ID : "LENOVO"
[010h 0016 8] Oem Table ID : "CB-01 "
[018h 0024 4] Oem Revision : 00000001
[01Ch 0028 4] Asl Compiler ID : "ACPI"
[020h 0032 4] Asl Compiler Revision : 00040000
[024h 0036 4] Virtualization Info : 00203043
[028h 0040 8] Reserved : 0000000000000000
[030h 0048 1] Subtable Type : 10 [Hardware Definition Block (IVHD)]
[031h 0049 1] Flags (decoded below) : B0
HtTunEn : 0
PassPW : 0
ResPassPW : 0
Isoc Control : 0
Iotlb Support : 1
Coherent : 1
Prefetch Support : 0
PPR Support : 1
[032h 0050 2] Length : 0048
[034h 0052 2] DeviceId : 0002
[036h 0054 2] Capability Offset : 0040
[038h 0056 8] Base Address : 00000000A0400000
[040h 0064 2] PCI Segment Group : 0000
[042h 0066 2] Virtualization Info : 0000
[044h 0068 4] Feature Reporting : 80048F6E
[048h 0072 1] Subtable Type : 03 [Device Entry: Start of Range]
[049h 0073 2] Device ID : 0008
[04Bh 0075 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[04Ch 0076 1] Subtable Type : 04 [Device Entry: End of Range]
[04Dh 0077 2] Device ID : FFFE
[04Fh 0079 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[050h 0080 1] Subtable Type : 43 [Device Entry: Alias Start of Range]
[051h 0081 2] Device ID : FF00
[053h 0083 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[054h 0084 1] Reserved : 00
[055h 0085 2] Source Used Device ID : 00A5
[057h 0087 1] Reserved : 00
[058h 0088 1] Subtable Type : 04 [Device Entry: End of Range]
[059h 0089 2] Device ID : FFFF
[05Bh 0091 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[05Ch 0092 1] Subtable Type : 00 [Unknown/Reserved Device Entry Type]
[05Dh 0093 2] Device ID : 0000
[05Fh 0095 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[060h 0096 1] Subtable Type : 48 [Device Entry: Special Device]
[061h 0097 2] Device ID : 0000
[063h 0099 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[064h 0100 1] Handle : 00
[065h 0101 2] Source Used Device ID : 00A0
[067h 0103 1] Variety : 02
[068h 0104 1] Subtable Type : 48 [Device Entry: Special Device]
[069h 0105 2] Device ID : 0000
[06Bh 0107 1] Data Setting (decoded below) : D7
INITPass : 1
EIntPass : 1
NMIPass : 1
Reserved : 0
System MGMT : 1
LINT0 Pass : 1
LINT1 Pass : 1
[06Ch 0108 1] Handle : 21
[06Dh 0109 2] Source Used Device ID : 00A0
[06Fh 0111 1] Variety : 01
[070h 0112 1] Subtable Type : 48 [Device Entry: Special Device]
[071h 0113 2] Device ID : 0000
[073h 0115 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[074h 0116 1] Handle : 22
[075h 0117 2] Source Used Device ID : 0001
[077h 0119 1] Variety : 01
[078h 0120 1] Subtable Type : 11 [Hardware Definition Block (IVHD)]
[079h 0121 1] Flags (decoded below) : B0
HtTunEn : 0
PassPW : 0
ResPassPW : 0
Isoc Control : 0
Iotlb Support : 1
Coherent : 1
Prefetch Support : 0
PPR Support : 1
[07Ah 0122 2] Length : 0058
[07Ch 0124 2] DeviceId : 0002
[07Eh 0126 2] Capability Offset : 0040
[080h 0128 8] Base Address : 00000000A0400000
[088h 0136 2] PCI Segment Group : 0000
[08Ah 0138 2] Virtualization Info : 0000
[08Ch 0140 4] Attributes : 00040200
[090h 0144 8] EFR Image : 246577EFA2254AFA
[098h 0152 8] Reserved : 0000000000000000
[0A0h 0160 1] Subtable Type : 03 [Device Entry: Start of Range]
[0A1h 0161 2] Device ID : 0008
[0A3h 0163 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[0A4h 0164 1] Subtable Type : 04 [Device Entry: End of Range]
[0A5h 0165 2] Device ID : FFFE
[0A7h 0167 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[0A8h 0168 1] Subtable Type : 43 [Device Entry: Alias Start of Range]
[0A9h 0169 2] Device ID : FF00
[0ABh 0171 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[0ACh 0172 1] Reserved : 00
[0ADh 0173 2] Source Used Device ID : 00A5
[0AFh 0175 1] Reserved : 00
[0B0h 0176 1] Subtable Type : 04 [Device Entry: End of Range]
[0B1h 0177 2] Device ID : FFFF
[0B3h 0179 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[0B4h 0180 1] Subtable Type : 00 [Unknown/Reserved Device Entry Type]
[0B5h 0181 2] Device ID : 0000
[0B7h 0183 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[0B8h 0184 1] Subtable Type : 48 [Device Entry: Special Device]
[0B9h 0185 2] Device ID : 0000
[0BBh 0187 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[0BCh 0188 1] Handle : 00
[0BDh 0189 2] Source Used Device ID : 00A0
[0BFh 0191 1] Variety : 02
[0C0h 0192 1] Subtable Type : 48 [Device Entry: Special Device]
[0C1h 0193 2] Device ID : 0000
[0C3h 0195 1] Data Setting (decoded below) : D7
INITPass : 1
EIntPass : 1
NMIPass : 1
Reserved : 0
System MGMT : 1
LINT0 Pass : 1
LINT1 Pass : 1
[0C4h 0196 1] Handle : 21
[0C5h 0197 2] Source Used Device ID : 00A0
[0C7h 0199 1] Variety : 01
[0C8h 0200 1] Subtable Type : 48 [Device Entry: Special Device]
[0C9h 0201 2] Device ID : 0000
[0CBh 0203 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[0CCh 0204 1] Handle : 22
[0CDh 0205 2] Source Used Device ID : 0001
[0CFh 0207 1] Variety : 01
[0D0h 0208 1] Subtable Type : 40 [Hardware Definition Block - Mixed Format (IVHD)]
[0D1h 0209 1] Flags (decoded below) : B0
HtTunEn : 0
PassPW : 0
ResPassPW : 0
Isoc Control : 0
Iotlb Support : 1
Coherent : 1
Prefetch Support : 0
PPR Support : 1
[0D2h 0210 2] Length : 00D4
[0D4h 0212 2] DeviceId : 0002
[0D6h 0214 2] Capability Offset : 0040
[0D8h 0216 8] Base Address : 00000000A0400000
[0E0h 0224 2] PCI Segment Group : 0000
[0E2h 0226 2] Virtualization Info : 0000
[0E4h 0228 4] Attributes : 00040200
[0E8h 0232 8] EFR Image : 246577EFA2254AFA
[0F0h 0240 8] Reserved : 0000000000000000
[0F8h 0248 1] Subtable Type : 03 [Device Entry: Start of Range]
[0F9h 0249 2] Device ID : 0008
[0FBh 0251 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[0FCh 0252 1] Subtable Type : 04 [Device Entry: End of Range]
[0FDh 0253 2] Device ID : FFFE
[0FFh 0255 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[100h 0256 1] Subtable Type : 43 [Device Entry: Alias Start of Range]
[101h 0257 2] Device ID : FF00
[103h 0259 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[104h 0260 1] Reserved : 00
[105h 0261 2] Source Used Device ID : 00A5
[107h 0263 1] Reserved : 00
[108h 0264 1] Subtable Type : 04 [Device Entry: End of Range]
[109h 0265 2] Device ID : FFFF
[10Bh 0267 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[10Ch 0268 1] Subtable Type : 00 [Unknown/Reserved Device Entry Type]
[10Dh 0269 2] Device ID : 0000
[10Fh 0271 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[110h 0272 1] Subtable Type : 48 [Device Entry: Special Device]
[111h 0273 2] Device ID : 0000
[113h 0275 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[114h 0276 1] Handle : 00
[115h 0277 2] Source Used Device ID : 00A0
[117h 0279 1] Variety : 02
[118h 0280 1] Subtable Type : 48 [Device Entry: Special Device]
[119h 0281 2] Device ID : 0000
[11Bh 0283 1] Data Setting (decoded below) : D7
INITPass : 1
EIntPass : 1
NMIPass : 1
Reserved : 0
System MGMT : 1
LINT0 Pass : 1
LINT1 Pass : 1
[11Ch 0284 1] Handle : 21
[11Dh 0285 2] Source Used Device ID : 00A0
[11Fh 0287 1] Variety : 01
[120h 0288 1] Subtable Type : 48 [Device Entry: Special Device]
[121h 0289 2] Device ID : 0000
[123h 0291 1] Data Setting (decoded below) : 00
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 0
LINT1 Pass : 0
[124h 0292 1] Handle : 22
[125h 0293 2] Source Used Device ID : 0001
[127h 0295 1] Variety : 01
[128h 0296 1] Subtable Type : F0 [Device Entry: ACPI HID Named Device]
[129h 0297 2] Device ID : 00A5
[12Bh 0299 1] Data Setting (decoded below) : 40
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 1
LINT1 Pass : 0
[12Ch 0300 8] ACPI HID : "AMDI0020"
[134h 0308 8] ACPI CID : 0000000000000000
[13Ch 0316 1] UID Format : 02
[13Dh 0317 1] UID Length : 09
[13Eh 0318 9] UID : "\_SB.FUR0"
[147h 0327 1] Subtable Type : F0 [Device Entry: ACPI HID Named Device]
[148h 0328 2] Device ID : 00A5
[14Ah 0330 1] Data Setting (decoded below) : 40
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 1
LINT1 Pass : 0
[14Bh 0331 8] ACPI HID : "AMDI0020"
[153h 0339 8] ACPI CID : 0000000000000000
[15Bh 0347 1] UID Format : 02
[15Ch 0348 1] UID Length : 09
[15Dh 0349 9] UID : "\_SB.FUR1"
[166h 0358 1] Subtable Type : F0 [Device Entry: ACPI HID Named Device]
[167h 0359 2] Device ID : 00A5
[169h 0361 1] Data Setting (decoded below) : 40
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 1
LINT1 Pass : 0
[16Ah 0362 8] ACPI HID : "AMDI0020"
[172h 0370 8] ACPI CID : 0000000000000000
[17Ah 0378 1] UID Format : 02
[17Bh 0379 1] UID Length : 09
[17Ch 0380 9] UID : "\_SB.FUR2"
[185h 0389 1] Subtable Type : F0 [Device Entry: ACPI HID Named Device]
[186h 0390 2] Device ID : 00A5
[188h 0392 1] Data Setting (decoded below) : 40
INITPass : 0
EIntPass : 0
NMIPass : 0
Reserved : 0
System MGMT : 0
LINT0 Pass : 1
LINT1 Pass : 0
[189h 0393 8] ACPI HID : "AMDI0020"
[191h 0401 8] ACPI CID : 0000000000000000
[199h 0409 1] UID Format : 02
[19Ah 0410 1] UID Length : 09
[19Bh 0411 9] UID : "\_SB.FUR3"
Raw Table Data: Length 420 (0x1A4)
0000: 49 56 52 53 A4 01 00 00 02 64 4C 45 4E 4F 56 4F // IVRS.....dLENOVO
0010: 43 42 2D 30 31 20 20 20 01 00 00 00 41 43 50 49 // CB-01 ....ACPI
0020: 00 00 04 00 43 30 20 00 00 00 00 00 00 00 00 00 // ....C0 .........
0030: 10 B0 48 00 02 00 40 00 00 00 40 A0 00 00 00 00 // ..H...@...@.....
0040: 00 00 00 00 6E 8F 04 80 03 08 00 00 04 FE FF 00 // ....n...........
0050: 43 00 FF 00 00 A5 00 00 04 FF FF 00 00 00 00 00 // C...............
0060: 48 00 00 00 00 A0 00 02 48 00 00 D7 21 A0 00 01 // H.......H...!...
0070: 48 00 00 00 22 01 00 01 11 B0 58 00 02 00 40 00 // H...".....X...@.
0080: 00 00 40 A0 00 00 00 00 00 00 00 00 00 02 04 00 // ..@.............
0090: FA 4A 25 A2 EF 77 65 24 00 00 00 00 00 00 00 00 // .J%..we$........
00A0: 03 08 00 00 04 FE FF 00 43 00 FF 00 00 A5 00 00 // ........C.......
00B0: 04 FF FF 00 00 00 00 00 48 00 00 00 00 A0 00 02 // ........H.......
00C0: 48 00 00 D7 21 A0 00 01 48 00 00 00 22 01 00 01 // H...!...H..."...
00D0: 40 B0 D4 00 02 00 40 00 00 00 40 A0 00 00 00 00 // @.....@...@.....
00E0: 00 00 00 00 00 02 04 00 FA 4A 25 A2 EF 77 65 24 // .........J%..we$
00F0: 00 00 00 00 00 00 00 00 03 08 00 00 04 FE FF 00 // ................
0100: 43 00 FF 00 00 A5 00 00 04 FF FF 00 00 00 00 00 // C...............
0110: 48 00 00 00 00 A0 00 02 48 00 00 D7 21 A0 00 01 // H.......H...!...
0120: 48 00 00 00 22 01 00 01 F0 A5 00 40 41 4D 44 49 // H..."......@AMDI
0130: 30 30 32 30 00 00 00 00 00 00 00 00 02 09 5C 5F // 0020..........\_
0140: 53 42 2E 46 55 52 30 F0 A5 00 40 41 4D 44 49 30 // SB.FUR0...@AMDI0
0150: 30 32 30 00 00 00 00 00 00 00 00 02 09 5C 5F 53 // 020..........\_S
0160: 42 2E 46 55 52 31 F0 A5 00 40 41 4D 44 49 30 30 // B.FUR1...@AMDI00
0170: 32 30 00 00 00 00 00 00 00 00 02 09 5C 5F 53 42 // 20..........\_SB
0180: 2E 46 55 52 32 F0 A5 00 40 41 4D 44 49 30 30 32 // .FUR2...@AMDI002
0190: 30 00 00 00 00 00 00 00 00 02 09 5C 5F 53 42 2E // 0..........\_SB.
01A0: 46 55 52 33 // FUR3

@ -0,0 +1,36 @@
/*
* Intel ACPI Component Architecture
* AML/ASL+ Disassembler version 20220331 (64-bit version)
* Copyright (c) 2000 - 2022 Intel Corporation
*
* Disassembly of mcfg.dat, Thu Sep 1 23:24:17 2022
*
* ACPI Data Table [MCFG]
*
* Format: [HexOffset DecimalOffset ByteLength] FieldName : FieldValue (in hex)
*/
[000h 0000 4] Signature : "MCFG" [Memory Mapped Configuration Table]
[004h 0004 4] Table Length : 0000003C
[008h 0008 1] Revision : 01
[009h 0009 1] Checksum : 5F
[00Ah 0010 6] Oem ID : "LENOVO"
[010h 0016 8] Oem Table ID : "CB-01 "
[018h 0024 4] Oem Revision : 00000001
[01Ch 0028 4] Asl Compiler ID : "ACPI"
[020h 0032 4] Asl Compiler Revision : 00040000
[024h 0036 8] Reserved : 0000000000000000
[02Ch 0044 8] Base Address : 00000000E0000000
[034h 0052 2] Segment Group Number : 0000
[036h 0054 1] Start Bus Number : 00
[037h 0055 1] End Bus Number : FF
[038h 0056 4] Reserved : 00000000
Raw Table Data: Length 60 (0x3C)
0000: 4D 43 46 47 3C 00 00 00 01 5F 4C 45 4E 4F 56 4F // MCFG<...._LENOVO
0010: 43 42 2D 30 31 20 20 20 01 00 00 00 41 43 50 49 // CB-01 ....ACPI
0020: 00 00 04 00 00 00 00 00 00 00 00 00 00 00 00 E0 // ................
0030: 00 00 00 00 00 00 00 FF 00 00 00 00 // ............

@ -0,0 +1,34 @@
/*
* Intel ACPI Component Architecture
* AML/ASL+ Disassembler version 20220331 (64-bit version)
* Copyright (c) 2000 - 2022 Intel Corporation
*
* Disassembly of poat.dat, Thu Sep 1 23:24:17 2022
*
* ACPI Data Table [POAT]
*
* Format: [HexOffset DecimalOffset ByteLength] FieldName : FieldValue (in hex)
*/
[000h 0000 4] Signature : "POAT"
[004h 0004 4] Table Length : 00000055
[008h 0008 1] Revision : 03
[009h 0009 1] Checksum : 2E
[00Ah 0010 6] Oem ID : "LENOVO"
[010h 0016 8] Oem Table ID : "CB-01 "
[018h 0024 4] Oem Revision : 00000001
[01Ch 0028 4] Asl Compiler ID : "ACPI"
[020h 0032 4] Asl Compiler Revision : 00040000
**** Unknown ACPI table signature [POAT]
Raw Table Data: Length 85 (0x55)
0000: 50 4F 41 54 55 00 00 00 03 2E 4C 45 4E 4F 56 4F // POATU.....LENOVO
0010: 43 42 2D 30 31 20 20 20 01 00 00 00 41 43 50 49 // CB-01 ....ACPI
0020: 00 00 04 00 01 00 00 00 FF FF FF FF 01 00 00 00 // ................
0030: FF FF FF FF 01 00 00 00 FF FF FF FF FF FF FF FF // ................
0040: FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF // ................
0050: FF FF FF FF FF // .....

@ -0,0 +1,71 @@
/*
* Intel ACPI Component Architecture
* AML/ASL+ Disassembler version 20220331 (64-bit version)
* Copyright (c) 2000 - 2022 Intel Corporation
*
* Disassembly of slic.dat, Thu Sep 1 23:24:17 2022
*
* ACPI Data Table [SLIC]
*
* Format: [HexOffset DecimalOffset ByteLength] FieldName : FieldValue (in hex)
*/
[000h 0000 4] Signature : "SLIC" [Software Licensing Description Table]
[004h 0004 4] Table Length : 00000176
[008h 0008 1] Revision : 01
[009h 0009 1] Checksum : 9B
[00Ah 0010 6] Oem ID : "LENOVO"
[010h 0016 8] Oem Table ID : "CB-01 "
[018h 0024 4] Oem Revision : 00000001
[01Ch 0028 4] Asl Compiler ID : "ACPI"
[020h 0032 4] Asl Compiler Revision : 00040000
[024h 0036 338] Software Licensing Structure : 53 4C 49 43 76 01 00 00 01 9B 4C 45 4E 4F 56 4F /* SLICv.....LENOVO */\
/* 034h 0052 16 */ 43 42 2D 30 31 20 20 20 01 00 00 00 41 43 50 49 /* CB-01 ....ACPI */\
/* 044h 0068 16 */ 00 00 04 00 00 00 00 00 9C 00 00 00 06 02 00 00 /* ................ */\
/* 054h 0084 16 */ 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 /* .$..RSA1........ */\
/* 064h 0100 16 */ 69 16 4A 9F B1 4B 3A FB 80 20 AA AF C4 F9 3E C1 /* i.J..K:.. ....>. */\
/* 074h 0116 16 */ 80 49 EE 6A 65 26 72 1E CD BF 5F 2F 96 D6 C0 0A /* .I.je&r..._/.... */\
/* 084h 0132 16 */ 92 F5 06 B5 00 B2 3B 29 02 E2 4C 8D C2 F2 BC 41 /* ......;)..L....A */\
/* 094h 0148 16 */ 77 9C 70 F0 F3 1B 09 D2 63 5A DC A8 83 F8 5E C9 /* w.p.....cZ....^. */\
/* 0A4h 0164 16 */ 15 95 F9 FA FD DC 05 B7 4D 67 7F 2D B3 84 33 20 /* ........Mg.-..3 */\
/* 0B4h 0180 16 */ E1 D1 79 2A A7 6A 77 D1 B6 20 2A 76 42 C5 D5 E9 /* ..y*.jw.. *vB... */\
/* 0C4h 0196 16 */ B6 43 40 55 44 C3 C9 37 99 5F 41 97 70 F3 D1 F6 /* .C@UD..7._A.p... */\
/* 0D4h 0212 16 */ 07 EC 7B 1A 29 A1 C1 F1 91 FD 48 86 6E 3E CE CB /* ..{.).....H.n>.. */\
/* 0E4h 0228 16 */ 01 00 00 00 B6 00 00 00 00 20 00 00 49 4E 53 59 /* ......... ..INSY */\
/* 0F4h 0244 16 */ 44 45 49 4E 53 59 44 45 30 30 57 49 4E 44 4F 57 /* DEINSYDE00WINDOW */\
/* 104h 0260 16 */ 53 20 01 00 02 00 00 00 00 00 00 00 00 00 00 00 /* S .............. */\
/* 114h 0276 16 */ 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 /* ................ */\
/* 124h 0292 16 */ 00 00 00 00 00 00 D9 54 93 7A 68 04 4A 44 81 CE /* .......T.zh.JD.. */\
/* 134h 0308 16 */ 0B F6 17 D8 90 DF 00 00 01 00 00 00 00 00 5F 46 /* .............._F */\
/* 144h 0324 16 */ 56 48 FF 8E FF FF 48 00 B1 4C 00 00 00 01 01 00 /* VH....H..L...... */\
/* 154h 0340 16 */ 00 00 00 00 01 00 00 00 00 00 00 00 00 00 54 F0 /* ..............T. */\
/* 164h 0356 16 */ 0C 6F 6A AE 8C 41 A7 CE 3C 7A 7C D7 4E C0 4E D4 /* .oj..A..<z|.N.N. */\
/* 174h 0372 2 */ 02 40 /* .@ */\
Raw Table Data: Length 374 (0x176)
0000: 53 4C 49 43 76 01 00 00 01 9B 4C 45 4E 4F 56 4F // SLICv.....LENOVO
0010: 43 42 2D 30 31 20 20 20 01 00 00 00 41 43 50 49 // CB-01 ....ACPI
0020: 00 00 04 00 00 00 00 00 9C 00 00 00 06 02 00 00 // ................
0030: 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 // .$..RSA1........
0040: 69 16 4A 9F B1 4B 3A FB 80 20 AA AF C4 F9 3E C1 // i.J..K:.. ....>.
0050: 80 49 EE 6A 65 26 72 1E CD BF 5F 2F 96 D6 C0 0A // .I.je&r..._/....
0060: 92 F5 06 B5 00 B2 3B 29 02 E2 4C 8D C2 F2 BC 41 // ......;)..L....A
0070: 77 9C 70 F0 F3 1B 09 D2 63 5A DC A8 83 F8 5E C9 // w.p.....cZ....^.
0080: 15 95 F9 FA FD DC 05 B7 4D 67 7F 2D B3 84 33 20 // ........Mg.-..3
0090: E1 D1 79 2A A7 6A 77 D1 B6 20 2A 76 42 C5 D5 E9 // ..y*.jw.. *vB...
00A0: B6 43 40 55 44 C3 C9 37 99 5F 41 97 70 F3 D1 F6 // .C@UD..7._A.p...
00B0: 07 EC 7B 1A 29 A1 C1 F1 91 FD 48 86 6E 3E CE CB // ..{.).....H.n>..
00C0: 01 00 00 00 B6 00 00 00 00 20 00 00 49 4E 53 59 // ......... ..INSY
00D0: 44 45 49 4E 53 59 44 45 30 30 57 49 4E 44 4F 57 // DEINSYDE00WINDOW
00E0: 53 20 01 00 02 00 00 00 00 00 00 00 00 00 00 00 // S ..............
00F0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ................
0100: 00 00 00 00 00 00 D9 54 93 7A 68 04 4A 44 81 CE // .......T.zh.JD..
0110: 0B F6 17 D8 90 DF 00 00 01 00 00 00 00 00 5F 46 // .............._F
0120: 56 48 FF 8E FF FF 48 00 B1 4C 00 00 00 01 01 00 // VH....H..L......
0130: 00 00 00 00 01 00 00 00 00 00 00 00 00 00 54 F0 // ..............T.
0140: 0C 6F 6A AE 8C 41 A7 CE 3C 7A 7C D7 4E C0 4E D4 // .oj..A..<z|.N.N.
0150: 02 40 13 2D 00 F8 FB 2C 00 01 88 7D 00 00 01 EA // .@.-...,...}....
0160: 2C 00 00 88 7D 00 00 1C 28 87 6E FB B4 69 39 3F // ,...}...(.n..i9?
0170: DE FF CC CC 64 90 // ....d.

@ -0,0 +1,144 @@
/*
* Intel ACPI Component Architecture
* AML/ASL+ Disassembler version 20220331 (64-bit version)
* Copyright (c) 2000 - 2022 Intel Corporation
*
* Disassembling to symbolic ASL+ operators
*
* Disassembly of ssdt1.dat, Thu Sep 1 23:24:17 2022
*
* Original Table Header:
* Signature "SSDT"
* Length 0x000001CC (460)
* Revision 0x01
* Checksum 0xC6
* OEM ID "LENOVO"
* OEM Table ID "CB-01 "
* OEM Revision 0x00000001 (1)
* Compiler ID "ACPI"
* Compiler Version 0x00040000 (262144)
*/
DefinitionBlock ("", "SSDT", 1, "LENOVO", "CB-01 ", 0x00000001)
{
External (_SB_.PCI0.GP18.SATA, DeviceObj)
OperationRegion (PM00, SystemMemory, 0xFED80300, 0x0100)
Field (PM00, AnyAcc, NoLock, Preserve)
{
Offset (0x6A),
SWSP, 8
}
OperationRegion (SWRG, SystemIO, SWSP, 0x02)
Field (SWRG, AnyAcc, NoLock, Preserve)
{
SWCP, 8,
SWDP, 8
}
Scope (\_SB)
{
Name (STDS, One)
Name (STDD, One)
Name (SCPD, 0xD5)
Name (SCPU, 0xD6)
}
Scope (\_SB.PCI0.GP18.SATA)
{
Name (D0S0, One)
Name (D3S0, One)
PowerResource (P0S0, 0x00, 0x0000)
{
Method (_STA, 0, NotSerialized) // _STA: Status
{
Return (D0S0) /* \_SB_.PCI0.GP18.SATA.D0S0 */
}
Method (_ON, 0, NotSerialized) // _ON_: Power On
{
D0S0 = One
}
Method (_OFF, 0, NotSerialized) // _OFF: Power Off
{
D0S0 = Zero
}
}
PowerResource (P3S0, 0x00, 0x0000)
{
Method (_STA, 0, NotSerialized) // _STA: Status
{
Return (D3S0) /* \_SB_.PCI0.GP18.SATA.D3S0 */
}
Method (_ON, 0, NotSerialized) // _ON_: Power On
{
D3S0 = One
}
Method (_OFF, 0, NotSerialized) // _OFF: Power Off
{
D3S0 = Zero
}
}
Name (_PR0, Package (0x01) // _PR0: Power Resources for D0
{
P0S0
})
Name (_PR3, Package (0x01) // _PR3: Power Resources for D3hot
{
P3S0
})
Name (_DSD, Package (0x02) // _DSD: Device-Specific Data
{
ToUUID ("5025030f-842f-4ab4-a561-99a5189762d0") /* Unknown UUID */,
Package (0x01)
{
Package (0x02)
{
"StorageD3Enable",
One
}
}
})
Method (_S0W, 0, NotSerialized) // _S0W: S0 Device Wake State
{
If ((STDS == One))
{
Return (0x04)
}
Else
{
Return (Zero)
}
}
Method (_PS0, 0, NotSerialized) // _PS0: Power State 0
{
If ((STDS == One))
{
If ((STDD == Zero))
{
SWDP = Zero
SWCP = SCPU /* \_SB_.SCPU */
}
}
}
Method (_PS3, 0, NotSerialized) // _PS3: Power State 3
{
If ((STDS == One))
{
If ((STDD == Zero))
{
SWDP = Zero
SWCP = SCPD /* \_SB_.SCPD */
}
}
}
}
}

File diff suppressed because it is too large Load Diff

@ -0,0 +1,751 @@
/*
* Intel ACPI Component Architecture
* AML/ASL+ Disassembler version 20220331 (64-bit version)
* Copyright (c) 2000 - 2022 Intel Corporation
*
* Disassembling to symbolic ASL+ operators
*
* Disassembly of ssdt11.dat, Thu Sep 1 23:24:17 2022
*
* Original Table Header:
* Signature "SSDT"
* Length 0x00001590 (5520)
* Revision 0x01
* Checksum 0x27
* OEM ID "LENOVO"
* OEM Table ID "CB-01 "
* OEM Revision 0x00000001 (1)
* Compiler ID "ACPI"
* Compiler Version 0x00040000 (262144)
*/
DefinitionBlock ("", "SSDT", 1, "LENOVO", "CB-01 ", 0x00000001)
{
External (_SB_.ALIB, MethodObj) // 2 Arguments
External (_SB_.PCI0.GP17.VGA_, DeviceObj)
External (_SB_.PCI0.GP17.VGA_.AFN0, MethodObj) // 0 Arguments
External (_SB_.PCI0.GP17.VGA_.AFN1, MethodObj) // 1 Arguments
External (_SB_.PCI0.GP17.VGA_.AFN2, MethodObj) // 2 Arguments
External (_SB_.PCI0.GP17.VGA_.AFN3, MethodObj) // 2 Arguments
External (_SB_.PCI0.GP17.VGA_.AFN4, MethodObj) // 1 Arguments
External (_SB_.PCI0.GP17.VGA_.AFN5, MethodObj) // 0 Arguments
External (_SB_.PCI0.GP17.VGA_.AFN6, MethodObj) // 0 Arguments
External (_SB_.PCI0.GP17.VGA_.AFN7, MethodObj) // 1 Arguments
External (_SB_.PCI0.GP17.VGA_.AFN8, MethodObj) // 0 Arguments
External (_SB_.PCI0.GP17.VGA_.AFNC, MethodObj) // 2 Arguments
External (_SB_.PCI0.PB2_.SWUS.SWDS.VGA_.AFN0, MethodObj) // 0 Arguments
External (_SB_.PCI0.PB2_.SWUS.SWDS.VGA_.AFN1, MethodObj) // 1 Arguments
External (_SB_.PCI0.PB2_.SWUS.SWDS.VGA_.AFN2, MethodObj) // 2 Arguments
External (_SB_.PCI0.PB2_.SWUS.SWDS.VGA_.AFN3, MethodObj) // 2 Arguments
External (_SB_.PCI0.PB2_.SWUS.SWDS.VGA_.AFN4, MethodObj) // 1 Arguments
External (_SB_.PCI0.PB2_.SWUS.SWDS.VGA_.AFN5, MethodObj) // 0 Arguments
External (_SB_.PCI0.PB2_.SWUS.SWDS.VGA_.AFN6, MethodObj) // 0 Arguments
External (_SB_.PCI0.PB2_.SWUS.SWDS.VGA_.AFN7, MethodObj) // 1 Arguments
External (_SB_.PCI0.PB2_.SWUS.SWDS.VGA_.AFN8, MethodObj) // 0 Arguments
External (_SB_.PCI0.PB2_.SWUS.SWDS.VGA_.AFNC, MethodObj) // 2 Arguments
External (_SB_.PCI0.PB2_.VGA_.AFN0, MethodObj) // 0 Arguments
External (_SB_.PCI0.PB2_.VGA_.AFN1, MethodObj) // 1 Arguments
External (_SB_.PCI0.PB2_.VGA_.AFN2, MethodObj) // 2 Arguments
External (_SB_.PCI0.PB2_.VGA_.AFN3, MethodObj) // 2 Arguments
External (_SB_.PCI0.PB2_.VGA_.AFN4, MethodObj) // 1 Arguments
External (_SB_.PCI0.PB2_.VGA_.AFN5, MethodObj) // 0 Arguments
External (_SB_.PCI0.PB2_.VGA_.AFN6, MethodObj) // 0 Arguments
External (_SB_.PCI0.PB2_.VGA_.AFN7, MethodObj) // 1 Arguments
External (_SB_.PCI0.PB2_.VGA_.AFN8, MethodObj) // 0 Arguments
External (_SB_.PCI0.PB2_.VGA_.AFNC, MethodObj) // 2 Arguments
External (M000, MethodObj) // 1 Arguments
External (M037, DeviceObj)
External (M046, IntObj)
External (M049, MethodObj) // 2 Arguments
External (M050, DeviceObj)
External (M051, DeviceObj)
External (M052, DeviceObj)
External (M053, DeviceObj)
External (M054, DeviceObj)
External (M055, DeviceObj)
External (M056, DeviceObj)
External (M057, DeviceObj)
External (M058, DeviceObj)
External (M059, DeviceObj)
External (M062, DeviceObj)
External (M068, DeviceObj)
External (M069, DeviceObj)
External (M070, DeviceObj)
External (M071, DeviceObj)
External (M072, DeviceObj)
External (M074, DeviceObj)
External (M075, DeviceObj)
External (M076, DeviceObj)
External (M077, DeviceObj)
External (M078, DeviceObj)
External (M079, DeviceObj)
External (M080, DeviceObj)
External (M081, DeviceObj)
External (M082, FieldUnitObj)
External (M083, FieldUnitObj)
External (M084, FieldUnitObj)
External (M085, FieldUnitObj)
External (M086, FieldUnitObj)
External (M087, FieldUnitObj)
External (M088, FieldUnitObj)
External (M089, FieldUnitObj)
External (M090, FieldUnitObj)
External (M091, FieldUnitObj)
External (M092, FieldUnitObj)
External (M093, FieldUnitObj)
External (M094, FieldUnitObj)
External (M095, FieldUnitObj)
External (M096, FieldUnitObj)
External (M097, FieldUnitObj)
External (M098, FieldUnitObj)
External (M099, FieldUnitObj)
External (M100, FieldUnitObj)
External (M101, FieldUnitObj)
External (M102, FieldUnitObj)
External (M103, FieldUnitObj)
External (M104, FieldUnitObj)
External (M105, FieldUnitObj)
External (M106, FieldUnitObj)
External (M107, FieldUnitObj)
External (M108, FieldUnitObj)
External (M109, FieldUnitObj)
External (M110, FieldUnitObj)
External (M113, MethodObj) // 1 Arguments
External (M115, BuffObj)
External (M116, BuffFieldObj)
External (M117, BuffFieldObj)
External (M118, BuffFieldObj)
External (M119, BuffFieldObj)
External (M120, BuffFieldObj)
External (M122, FieldUnitObj)
External (M127, DeviceObj)
External (M128, FieldUnitObj)
External (M131, FieldUnitObj)
External (M132, FieldUnitObj)
External (M133, FieldUnitObj)
External (M134, FieldUnitObj)
External (M135, FieldUnitObj)
External (M136, FieldUnitObj)
External (M220, FieldUnitObj)
External (M221, FieldUnitObj)
External (M226, FieldUnitObj)
External (M227, DeviceObj)
External (M229, FieldUnitObj)
External (M231, FieldUnitObj)
External (M232, MethodObj) // 3 Arguments
External (M233, FieldUnitObj)
External (M235, FieldUnitObj)
External (M23A, FieldUnitObj)
External (M251, FieldUnitObj)
External (M280, FieldUnitObj)
External (M290, FieldUnitObj)
External (M310, FieldUnitObj)
External (M31C, FieldUnitObj)
External (M320, FieldUnitObj)
External (M321, FieldUnitObj)
External (M322, FieldUnitObj)
External (M323, FieldUnitObj)
External (M324, FieldUnitObj)
External (M325, FieldUnitObj)
External (M326, FieldUnitObj)
External (M327, FieldUnitObj)
External (M328, FieldUnitObj)
External (M329, DeviceObj)
External (M32A, DeviceObj)
External (M32B, DeviceObj)
External (M330, DeviceObj)
External (M331, FieldUnitObj)
External (M378, FieldUnitObj)
External (M379, FieldUnitObj)
External (M380, FieldUnitObj)
External (M381, FieldUnitObj)
External (M382, FieldUnitObj)
External (M383, FieldUnitObj)
External (M384, FieldUnitObj)
External (M385, FieldUnitObj)
External (M386, FieldUnitObj)
External (M387, FieldUnitObj)
External (M388, FieldUnitObj)
External (M389, FieldUnitObj)
External (M390, FieldUnitObj)
External (M391, FieldUnitObj)
External (M392, FieldUnitObj)
External (M404, DeviceObj)
External (M414, FieldUnitObj)
External (M444, FieldUnitObj)
External (M449, FieldUnitObj)
External (M453, FieldUnitObj)
External (M454, FieldUnitObj)
External (M455, FieldUnitObj)
External (M456, FieldUnitObj)
External (M457, FieldUnitObj)
External (M4C0, FieldUnitObj)
External (M4F0, FieldUnitObj)
Scope (\_SB.PCI0.GP17.VGA)
{
Name (M207, Buffer (0xFF){})
Name (M208, Buffer (0x03){})
Name (M204, One)
Method (ATCS, 2, Serialized)
{
If ((Arg0 == Zero))
{
M000 (0x0D60)
ATC0 ()
M000 (0x0D70)
}
If ((Arg0 == One))
{
M000 (0x0D61)
ATC1 ()
M000 (0x0D71)
}
If ((Arg0 == 0x02))
{
M000 (0x0D62)
ATC2 (Arg1)
M000 (0x0D72)
}
If ((Arg0 == 0x03))
{
M000 (0x0D63)
ATC3 ()
M000 (0x0D73)
}
If ((Arg0 == 0x04))
{
M000 (0x0D64)
ATC4 (Arg1)
M000 (0x0D74)
}
If ((Arg0 == 0x06))
{
M000 (0x0D66)
ATC6 (Arg1)
M000 (0x0D76)
}
If ((Arg0 == 0x07))
{
M000 (0x0D67)
ATC7 (Arg1)
M000 (0x0D77)
}
If ((Arg0 == 0x08))
{
M000 (0x0D68)
ATC8 (DerefOf (Arg1 [0x02]), DerefOf (Arg1 [0x03]), DerefOf (
Arg1 [0x04]), DerefOf (Arg1 [0x05]))
M000 (0x0D78)
}
If ((Arg0 == 0x09))
{
M000 (0x0D69)
ATC9 ()
M000 (0x0D79)
}
If ((Arg0 == 0x0A))
{
M000 (0x0D6A)
ATCA (Arg1)
M000 (0x0D7A)
}
Return (M207) /* \_SB_.PCI0.GP17.VGA_.M207 */
}
Method (ATC0, 0, NotSerialized)
{
CreateWordField (M207, Zero, M157)
CreateWordField (M207, 0x02, M158)
CreateDWordField (M207, 0x04, M160)
M157 = 0x08
M158 = One
M160 = M100 /* External reference */
M207 = \_SB.ALIB (Zero, M207)
}
Method (ATC1, 0, Serialized)
{
CreateWordField (M207, Zero, M157)
CreateDWordField (M207, 0x02, M161)
CreateDWordField (M207, 0x06, M162)
CreateField (M207, 0x30, One, M203)
M157 = 0x0A
M161 = One
M162 = M100 /* External reference */
Local0 = M049 (M133, 0x15)
If ((Local0 & 0x80))
{
M204 = (Local0 & One)
}
ElseIf ((Local0 & 0x7F))
{
M204 = M113 (Local0)
}
M203 = M204 /* \_SB_.PCI0.GP17.VGA_.M204 */
}
Method (ATC2, 1, Serialized)
{
CreateWordField (M207, Zero, M157)
CreateByteField (M207, 0x02, M205)
M157 = 0x03
M205 = One
M207 = \_SB.ALIB (0x02, Arg0)
}
Method (ATC3, 0, Serialized)
{
CreateWordField (M207, Zero, M157)
CreateByteField (M207, 0x02, M205)
CreateWordField (M208, Zero, M197)
CreateByteField (M208, 0x02, M206)
M157 = 0x03
M205 = One
M197 = 0x03
M206 = One
M207 = \_SB.ALIB (0x03, M208)
}
Method (ATC4, 1, Serialized)
{
CreateWordField (M207, Zero, M157)
CreateByteField (M207, 0x02, M209)
M157 = 0x03
M209 = One
M207 = \_SB.ALIB (0x04, Arg0)
}
Method (ATC6, 1, Serialized)
{
CreateWordField (M207, Zero, M157)
CreateDWordField (M207, 0x02, M234)
M157 = 0x06
M234 = M233 /* External reference */
}
Method (ATC7, 1, Serialized)
{
M232 (M235, Zero, One)
}
Method (ATC8, 4, Serialized)
{
Local0 = Buffer (0x05){}
CreateWordField (Local0, Zero, M157)
CreateByteField (Local0, 0x02, M425)
CreateWordField (Local0, 0x03, M426)
M157 = 0x05
Local1 = Arg0
Local2 = Arg1
M426 = ((Local2 << 0x08) + Local1)
Local3 = Arg2
Local4 = Arg3
If (((Local3 == Zero) && (Local4 == Zero)))
{
M425 = One
\_SB.ALIB (0xAA, Local0)
}
ElseIf (((Local3 == Zero) && (Local4 == One)))
{
M425 = Zero
\_SB.ALIB (0xAA, Local0)
}
ElseIf (((Local3 == 0x03) && (Local4 == One)))
{
M425 = 0x03
\_SB.ALIB (0xAA, Local0)
}
}
Method (ATC9, 0, Serialized)
{
M207 = M444 /* External reference */
}
Method (ATCA, 1, Serialized)
{
CreateWordField (Arg0, Zero, M157)
CreateWordField (Arg0, 0x02, M240)
M232 (M23A, M240, One)
}
Method (XTRM, 2, Serialized)
{
If ((M105 == Zero))
{
Return (Buffer (One)
{
0x00 // .
})
}
Local4 = M105 /* External reference */
If ((Local4 > 0x00010000))
{
Local4 = 0x00010000
}
Local5 = Arg0
Local6 = Arg1
If ((Local6 > 0x1000))
{
Local6 = 0x1000
}
If ((Local5 >= Local4))
{
Return (Buffer (Local6)
{
0x00 // .
})
}
If ((((Local5 & 0x0FFF) + Local6) > 0x1000))
{
Local6 = (0x1000 - (Local5 & 0x0FFF))
}
Name (M202, Buffer (0x1000)
{
0x00 // .
})
If (((Local5 & 0xF000) == Zero))
{
M202 = M106 /* External reference */
}
ElseIf (((Local5 & 0xF000) == 0x1000))
{
M202 = M378 /* External reference */
}
ElseIf (((Local5 & 0xF000) == 0x2000))
{
M202 = M379 /* External reference */
}
ElseIf (((Local5 & 0xF000) == 0x3000))
{
M202 = M380 /* External reference */
}
ElseIf (((Local5 & 0xF000) == 0x4000))
{
M202 = M381 /* External reference */
}
ElseIf (((Local5 & 0xF000) == 0x5000))
{
M202 = M382 /* External reference */
}
ElseIf (((Local5 & 0xF000) == 0x6000))
{
M202 = M383 /* External reference */
}
ElseIf (((Local5 & 0xF000) == 0x7000))
{
M202 = M384 /* External reference */
}
ElseIf (((Local5 & 0xF000) == 0x8000))
{
M202 = M385 /* External reference */
}
ElseIf (((Local5 & 0xF000) == 0x9000))
{
M202 = M386 /* External reference */
}
ElseIf (((Local5 & 0xF000) == 0xA000))
{
M202 = M387 /* External reference */
}
ElseIf (((Local5 & 0xF000) == 0xB000))
{
M202 = M388 /* External reference */
}
ElseIf (((Local5 & 0xF000) == 0xC000))
{
M202 = M389 /* External reference */
}
ElseIf (((Local5 & 0xF000) == 0xD000))
{
M202 = M390 /* External reference */
}
ElseIf (((Local5 & 0xF000) == 0xE000))
{
M202 = M391 /* External reference */
}
ElseIf (((Local5 & 0xF000) == 0xF000))
{
M202 = M392 /* External reference */
}
If (((Local5 + Local6) <= Local4))
{
If ((Local6 == 0x1000))
{
Return (M202) /* \_SB_.PCI0.GP17.VGA_.XTRM.M202 */
}
}
Else
{
Local6 = (Local4 - Local5)
}
Name (M393, Buffer (Local6)
{
0x00 // .
})
CreateField (M202, ((Local5 & 0x0FFF) * 0x08), (Local6 * 0x08
), M394)
M393 = M394 /* \_SB_.PCI0.GP17.VGA_.XTRM.M394 */
Return (M393) /* \_SB_.PCI0.GP17.VGA_.XTRM.M393 */
}
}
Method (AFN0, 0, Serialized)
{
If ((M087 == Zero))
{
If (CondRefOf (\_SB.PCI0.GP17.VGA.AFN0))
{
\_SB.PCI0.GP17.VGA.AFN0 ()
}
}
If ((M087 == One))
{
If (CondRefOf (\_SB.PCI0.PB2.VGA.AFN0))
{
\_SB.PCI0.PB2.VGA.AFN0 ()
}
If (CondRefOf (\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN0))
{
\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN0 ()
}
}
}
Method (AFN1, 1, Serialized)
{
If ((M087 == Zero))
{
If (CondRefOf (\_SB.PCI0.GP17.VGA.AFN1))
{
\_SB.PCI0.GP17.VGA.AFN1 (Arg0)
}
}
If ((M087 == One))
{
If (CondRefOf (\_SB.PCI0.PB2.VGA.AFN1))
{
\_SB.PCI0.PB2.VGA.AFN1 (Arg0)
}
If (CondRefOf (\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN1))
{
\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN1 (Arg0)
}
}
}
Method (AFN2, 2, Serialized)
{
If ((M087 == Zero))
{
If (CondRefOf (\_SB.PCI0.GP17.VGA.AFN2))
{
\_SB.PCI0.GP17.VGA.AFN2 (Arg0, Arg1)
}
}
If ((M087 == One))
{
If (CondRefOf (\_SB.PCI0.PB2.VGA.AFN2))
{
\_SB.PCI0.PB2.VGA.AFN2 (Arg0, Arg1)
}
If (CondRefOf (\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN2))
{
\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN2 (Arg0, Arg1)
}
}
}
Method (AFN3, 2, Serialized)
{
If ((M087 == Zero))
{
If (CondRefOf (\_SB.PCI0.GP17.VGA.AFN3))
{
\_SB.PCI0.GP17.VGA.AFN3 (Arg0, Arg1)
}
}
If ((M087 == One))
{
If (CondRefOf (\_SB.PCI0.PB2.VGA.AFN3))
{
\_SB.PCI0.PB2.VGA.AFN3 (Arg0, Arg1)
}
If (CondRefOf (\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN3))
{
\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN3 (Arg0, Arg1)
}
}
}
Method (AFN4, 1, Serialized)
{
If ((M087 == Zero))
{
If (CondRefOf (\_SB.PCI0.GP17.VGA.AFN4))
{
\_SB.PCI0.GP17.VGA.AFN4 (Arg0)
}
}
If ((M087 == One))
{
If (CondRefOf (\_SB.PCI0.PB2.VGA.AFN4))
{
\_SB.PCI0.PB2.VGA.AFN4 (Arg0)
}
If (CondRefOf (\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN4))
{
\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN4 (Arg0)
}
}
}
Method (AFN5, 0, Serialized)
{
If ((M087 == Zero))
{
If (CondRefOf (\_SB.PCI0.GP17.VGA.AFN5))
{
\_SB.PCI0.GP17.VGA.AFN5 ()
}
}
If ((M087 == One))
{
If (CondRefOf (\_SB.PCI0.PB2.VGA.AFN5))
{
\_SB.PCI0.PB2.VGA.AFN5 ()
}
If (CondRefOf (\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN5))
{
\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN5 ()
}
}
}
Method (AFN6, 0, Serialized)
{
If ((M087 == Zero))
{
If (CondRefOf (\_SB.PCI0.GP17.VGA.AFN6))
{
\_SB.PCI0.GP17.VGA.AFN6 ()
}
}
If ((M087 == One))
{
If (CondRefOf (\_SB.PCI0.PB2.VGA.AFN6))
{
\_SB.PCI0.PB2.VGA.AFN6 ()
}
If (CondRefOf (\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN6))
{
\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN6 ()
}
}
}
Method (AFN7, 1, Serialized)
{
If ((M087 == Zero))
{
If (CondRefOf (\_SB.PCI0.GP17.VGA.AFN7))
{
\_SB.PCI0.GP17.VGA.AFN7 (Arg0)
}
}
If ((M087 == One))
{
If (CondRefOf (\_SB.PCI0.PB2.VGA.AFN7))
{
\_SB.PCI0.PB2.VGA.AFN7 (Arg0)
}
If (CondRefOf (\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN7))
{
\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN7 (Arg0)
}
}
}
Method (AFN8, 0, Serialized)
{
If ((M087 == Zero))
{
If (CondRefOf (\_SB.PCI0.GP17.VGA.AFN8))
{
\_SB.PCI0.GP17.VGA.AFN8 ()
}
}
If ((M087 == One))
{
If (CondRefOf (\_SB.PCI0.PB2.VGA.AFN8))
{
\_SB.PCI0.PB2.VGA.AFN8 ()
}
If (CondRefOf (\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN8))
{
\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFN8 ()
}
}
}
Method (AFNC, 2, Serialized)
{
If ((M087 == Zero))
{
If (CondRefOf (\_SB.PCI0.GP17.VGA.AFNC))
{
\_SB.PCI0.GP17.VGA.AFNC (Arg0, Arg1)
}
}
If ((M087 == One))
{
If (CondRefOf (\_SB.PCI0.PB2.VGA.AFNC))
{
\_SB.PCI0.PB2.VGA.AFNC (Arg0, Arg1)
}
If (CondRefOf (\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFNC))
{
\_SB.PCI0.PB2.SWUS.SWDS.VGA.AFNC (Arg0, Arg1)
}
}
}
}

@ -0,0 +1,912 @@
/*
* Intel ACPI Component Architecture
* AML/ASL+ Disassembler version 20220331 (64-bit version)
* Copyright (c) 2000 - 2022 Intel Corporation
*
* Disassembling to symbolic ASL+ operators
*
* Disassembly of ssdt12.dat, Thu Sep 1 23:24:17 2022
*
* Original Table Header:
* Signature "SSDT"
* Length 0x00001980 (6528)
* Revision 0x01
* Checksum 0x28
* OEM ID "LENOVO"
* OEM Table ID "CB-01 "
* OEM Revision 0x00000001 (1)
* Compiler ID "ACPI"
* Compiler Version 0x00040000 (262144)
*/
DefinitionBlock ("", "SSDT", 1, "LENOVO", "CB-01 ", 0x00000001)
{
External (_SB_.PC00.GMHB, MethodObj) // 0 Arguments
External (_SB_.PCI0.LPC0.EC0_.CHIS, IntObj)
External (_SB_.PCI0.LPC0.EC0_.CMFC, MethodObj) // 0 Arguments
External (_SB_.PCI0.LPC0.EC0_.CPUS, IntObj)
External (_SB_.PCI0.LPC0.EC0_.CPUT, IntObj)
External (_SB_.PCI0.LPC0.EC0_.FA2S, IntObj)
External (_SB_.PCI0.LPC0.EC0_.FANS, IntObj)
External (_SB_.PCI0.LPC0.EC0_.GPUS, IntObj)
External (_SB_.PCI0.LPC0.EC0_.GPUT, IntObj)
External (_SB_.PCI0.LPC0.EC0_.MBEI, MethodObj) // 3 Arguments
External (_SB_.PCI0.LPC0.EC0_.RTMP, IntObj)
External (_SB_.PCI0.LPC0.EC0_.SBTS, IntObj)
External (_SB_.PCI0.LPC0.EC0_.SSDS, IntObj)
External (_SB_.PCI0.LPC0.EC0_.VPC0.GSBI, MethodObj) // 1 Arguments
External (_SB_.PCI0.LPC0.EC0_.WEID, IntObj)
Scope (\_SB)
{
Device (WM00)
{
Name (_HID, EisaId ("PNP0C14") /* Windows Management Instrumentation Device */) // _HID: Hardware ID
Name (_UID, "WM00") // _UID: Unique ID
Name (_WDG, Buffer (0x64)
{
/* 0000 */ 0xF0, 0x0C, 0x0D, 0x7B, 0x6C, 0x5D, 0x9E, 0x43, // ...{l].C
/* 0008 */ 0x86, 0xA5, 0xA3, 0x61, 0x9B, 0x62, 0x34, 0x92, // ...a.b4.
/* 0010 */ 0x45, 0x45, 0x03, 0x02, 0x01, 0xDB, 0xD7, 0x83, // EE......
/* 0018 */ 0x6D, 0x3C, 0xDC, 0x42, 0xBA, 0x1B, 0x56, 0xDA, // m<.B..V.
/* 0020 */ 0xA5, 0x97, 0xF2, 0xB2, 0x80, 0x00, 0x01, 0x08, // ........
/* 0028 */ 0xE3, 0x54, 0x7B, 0x77, 0xDC, 0xDD, 0x2C, 0x4B, // .T{w..,K
/* 0030 */ 0x8B, 0x88, 0x68, 0xA2, 0x6A, 0x88, 0x35, 0xD0, // ..h.j.5.
/* 0038 */ 0x41, 0x30, 0x01, 0x02, 0xA2, 0x22, 0x3D, 0x03, // A0..."=.
/* 0040 */ 0x54, 0x82, 0xB8, 0x46, 0xBB, 0x7B, 0x59, 0xC4, // T..F.{Y.
/* 0048 */ 0x88, 0xC9, 0x6A, 0x3F, 0x41, 0x31, 0x01, 0x02, // ..j?A1..
/* 0050 */ 0x21, 0x12, 0x90, 0x05, 0x66, 0xD5, 0xD1, 0x11, // !...f...
/* 0058 */ 0xB2, 0xF0, 0x00, 0xA0, 0xC9, 0x06, 0x29, 0x10, // ......).
/* 0060 */ 0x46, 0x45, 0x01, 0x00 // FE..
})
OperationRegion (SMIP, SystemIO, 0xB0, One)
Field (SMIP, ByteAcc, NoLock, Preserve)
{
IOB2, 8
}
OperationRegion (LNVS, SystemMemory, 0x7AEBA000, 0x0120)
Field (LNVS, AnyAcc, NoLock, Preserve)
{
SGNT, 32,
MCMD, 32,
SCMD, 32,
RCDE, 32,
DAT1, 32,
DAT2, 32,
DAT3, 32,
DAT4, 32,
BDAT, 2048
}
Name (BDBF, Buffer (0x0100){})
Mutex (MSMI, 0x00)
Name (LBUF, Package (0x05)
{
Zero,
Zero,
Zero,
Zero,
Zero
})
Method (LSMI, 6, Serialized)
{
Acquire (MSMI, 0xFFFF)
RCDE = Zero
MCMD = Arg0
SCMD = Arg1
DAT1 = Arg2
DAT2 = Arg3
DAT3 = Arg4
DAT4 = Arg5
IOB2 = 0xCC
LBUF [Zero] = RCDE /* \_SB_.WM00.RCDE */
LBUF [One] = DAT1 /* \_SB_.WM00.DAT1 */
LBUF [0x02] = DAT2 /* \_SB_.WM00.DAT2 */
LBUF [0x03] = DAT3 /* \_SB_.WM00.DAT3 */
LBUF [0x04] = DAT4 /* \_SB_.WM00.DAT4 */
Release (MSMI)
Return (LBUF) /* \_SB_.WM00.LBUF */
}
Method (WMEE, 3, NotSerialized)
{
If ((Arg0 == Zero))
{
If ((Arg1 == One))
{
CreateByteField (Arg2, Zero, TDA1)
CreateByteField (Arg2, One, TDA2)
CreateByteField (Arg2, 0x02, TDA3)
CreateByteField (Arg2, 0x03, TDA4)
Arg1--
LSMI (TDA1, Arg1, TDA2, TDA3, TDA4, Zero)
Return (DAT1) /* \_SB_.WM00.DAT1 */
}
ElseIf ((Arg1 == 0x02))
{
\_SB.PCI0.LPC0.EC0.CMFC ()
}
ElseIf ((Arg1 == 0x04))
{
\_SB.PCI0.LPC0.EC0.VPC0.GSBI (One)
}
}
ElseIf ((Arg0 == One))
{
If ((Arg1 == 0x03))
{
CreateDWordField (Arg2, Zero, BDA0)
CreateDWordField (Arg2, 0x04, BDA1)
CreateDWordField (Arg2, 0x08, BDA2)
CreateDWordField (Arg2, 0x0C, BDA3)
CreateDWordField (Arg2, 0x10, BDA4)
CreateDWordField (BDBF, Zero, BAAA)
BAAA = BDA4 /* \_SB_.WM00.WMEE.BDA4 */
BDAT = BDBF /* \_SB_.WM00.BDBF */
Arg1--
LSMI (0x02, Arg1, BDA0, BDA1, BDA2, BDA3)
Return (BAAA) /* \_SB_.WM00.WMEE.BAAA */
}
}
ElseIf ((Arg0 == 0x02))
{
If ((Arg1 == 0x05))
{
CreateDWordField (Arg2, Zero, GUI1)
CreateDWordField (Arg2, 0x04, GUI2)
CreateDWordField (Arg2, 0x08, GUI3)
CreateDWordField (Arg2, 0x0C, GUI4)
CreateDWordField (Arg2, 0x10, GUIV)
CreateDWordField (BDBF, Zero, GUV1)
GUV1 = GUIV /* \_SB_.WM00.WMEE.GUIV */
BDAT = BDBF /* \_SB_.WM00.BDBF */
Arg1--
LSMI (0x03, Arg1, GUI1, GUI2, GUI3, GUI4)
Return (RCDE) /* \_SB_.WM00.RCDE */
}
}
}
Method (WMA0, 3, NotSerialized)
{
OperationRegion (CMDE, SystemIO, 0x68, 0x05)
Field (CMDE, ByteAcc, Lock, Preserve)
{
EC68, 8,
Offset (0x02),
Offset (0x03),
Offset (0x04),
EC6C, 8
}
OperationRegion (CUPL, SystemMemory, (\_SB.PC00.GMHB () + 0x59A0), 0x10)
Field (CUPL, ByteAcc, NoLock, Preserve)
{
CPL1, 15,
Offset (0x04),
CPL2, 15
}
Name (REMA, Zero)
If ((Arg1 == One))
{
Return (One)
}
If ((Arg1 == 0x02))
{
Return (One)
}
If ((Arg1 == 0x03))
{
Local0 = \_SB.PCI0.LPC0.EC0.FANS /* External reference */
Local0 *= 0x64
Return (Local0)
}
If ((Arg1 == 0x04))
{
Local0 = ToInteger (Arg2)
Divide (Local0, 0x64, REMA, Local0)
EC6C = 0x46
Sleep (0x05)
EC68 = Local0
Return (Zero)
}
If ((Arg1 == 0x05))
{
Local0 = \_SB.PCI0.LPC0.EC0.FA2S /* External reference */
Local0 *= 0x64
Return (Local0)
}
If ((Arg1 == 0x06))
{
Local0 = ToInteger (Arg2)
Divide (Local0, 0x64, REMA, Local0)
EC6C = 0x46
Sleep (0x05)
EC68 = Local0
Return (Zero)
}
If ((Arg1 == 0x07))
{
Divide (CPL1, 0x08, REMA, Local0)
Return (Local0)
}
If ((Arg1 == 0x08))
{
Local0 = ToInteger (Arg2)
Local0 *= 0x08
CPL1 = Local0
Return (Zero)
}
If ((Arg1 == 0x09))
{
Divide (CPL2, 0x08, REMA, Local0)
Return (Local0)
}
If ((Arg1 == 0x0A))
{
Local0 = ToInteger (Arg2)
Local0 *= 0x08
CPL2 = Local0
Return (Zero)
}
If ((Arg1 == 0x0B))
{
Local0 = \_SB.PCI0.LPC0.EC0.CPUT /* External reference */
Return (Local0)
}
If ((Arg1 == 0x0C))
{
Local0 = \_SB.PCI0.LPC0.EC0.GPUT /* External reference */
Return (Local0)
}
If ((Arg1 == 0x0D))
{
Local0 = \_SB.PCI0.LPC0.EC0.CPUS /* External reference */
Return (Local0)
}
If ((Arg1 == 0x0E))
{
Local0 = \_SB.PCI0.LPC0.EC0.GPUS /* External reference */
Return (Local0)
}
If ((Arg1 == 0x0F))
{
Local0 = \_SB.PCI0.LPC0.EC0.CHIS /* External reference */
Return (Local0)
}
If ((Arg1 == 0x10))
{
Local0 = \_SB.PCI0.LPC0.EC0.SBTS /* External reference */
Return (Local0)
}
If ((Arg1 == 0x11))
{
Local0 = \_SB.PCI0.LPC0.EC0.SSDS /* External reference */
Return (Local0)
}
If ((Arg1 == 0x12))
{
Local0 = \_SB.PCI0.LPC0.EC0.RTMP /* External reference */
Return (Local0)
}
}
Method (WMA1, 3, NotSerialized)
{
Local0 = ToInteger (Arg2)
Local1 = (Local0 & 0xFF)
Local2 = ((Local0 >> 0x08) & 0xFF)
If ((Arg1 == One))
{
Return (\_SB.PCI0.LPC0.EC0.MBEI (0xED, Local1, Local2))
}
If ((Arg1 == 0x02))
{
Return (\_SB.PCI0.LPC0.EC0.MBEI (0xED, Local1, Local2))
}
If ((Arg1 == 0x03))
{
Return (\_SB.PCI0.LPC0.EC0.MBEI (0xEE, Local1, Local2))
}
If ((Arg1 == 0x04))
{
Return (\_SB.PCI0.LPC0.EC0.MBEI (0xEE, Local1, Local2))
}
If ((Arg1 == 0x05))
{
Return (\_SB.PCI0.LPC0.EC0.MBEI (0xEF, Local1, Local2))
}
If ((Arg1 == 0x06))
{
Return (\_SB.PCI0.LPC0.EC0.MBEI (0xEF, Local1, Local2))
}
}
Method (_WED, 1, NotSerialized) // _Wxx: Wake Event, xx=0x00-0xFF
{
Return (ToInteger (\_SB.PCI0.LPC0.EC0.WEID))
}
Name (WQFE, Buffer (0x1145)
{
/* 0000 */ 0x46, 0x4F, 0x4D, 0x42, 0x01, 0x00, 0x00, 0x00, // FOMB....
/* 0008 */ 0x35, 0x11, 0x00, 0x00, 0x86, 0x6A, 0x00, 0x00, // 5....j..
/* 0010 */ 0x44, 0x53, 0x00, 0x01, 0x1A, 0x7D, 0xDA, 0x54, // DS...}.T
/* 0018 */ 0x98, 0x5E, 0xB3, 0x00, 0x01, 0x06, 0x18, 0x42, // .^.....B
/* 0020 */ 0x10, 0x11, 0x10, 0x22, 0x21, 0x30, 0x34, 0x32, // ..."!042
/* 0028 */ 0x0B, 0x03, 0x63, 0x04, 0x8A, 0x0B, 0x21, 0x07, // ..c...!.
/* 0030 */ 0x10, 0x12, 0x07, 0x85, 0x12, 0x02, 0xA1, 0xFE, // ........
/* 0038 */ 0x04, 0xF2, 0x2B, 0x00, 0xA1, 0x43, 0x01, 0x32, // ..+..C.2
/* 0040 */ 0x05, 0x18, 0x14, 0xE0, 0x14, 0x41, 0x04, 0xBD, // .....A..
/* 0048 */ 0x0A, 0xB0, 0x29, 0xC0, 0xA4, 0x00, 0x8B, 0x02, // ..).....
/* 0050 */ 0xB4, 0x0B, 0xB0, 0x2C, 0x40, 0xB7, 0x00, 0xE9, // ...,@...
/* 0058 */ 0xB0, 0x44, 0x24, 0x38, 0x4A, 0x0C, 0x38, 0x4A, // .D$8J.8J
/* 0060 */ 0x27, 0xB6, 0x70, 0xC3, 0x06, 0x2F, 0x14, 0x45, // '.p../.E
/* 0068 */ 0x33, 0x88, 0x92, 0xA0, 0x72, 0x01, 0xBE, 0x11, // 3...r...
/* 0070 */ 0x04, 0x5E, 0xAE, 0x00, 0xC9, 0x13, 0xD0, 0xCA, // .^......
/* 0078 */ 0x1A, 0x16, 0x60, 0x5D, 0x80, 0xEC, 0x21, 0x50, // ..`]..!P
/* 0080 */ 0xA9, 0x43, 0x40, 0xC9, 0x19, 0x02, 0x6A, 0x00, // .C@...j.
/* 0088 */ 0xAD, 0x4E, 0x40, 0xF8, 0x95, 0x4E, 0x09, 0x49, // .N@..N.I
/* 0090 */ 0x10, 0xCE, 0x58, 0xC5, 0xE3, 0x6B, 0x16, 0x4D, // ..X..k.M
/* 0098 */ 0xCF, 0x49, 0xCE, 0x31, 0xE4, 0x78, 0x5C, 0xE8, // .I.1.x\.
/* 00A0 */ 0x41, 0xF0, 0x90, 0xA3, 0x45, 0xC5, 0x1A, 0x30, // A...E..0
/* 00A8 */ 0x3A, 0x12, 0x84, 0x14, 0x0C, 0x08, 0x3D, 0x60, // :.....=`
/* 00B0 */ 0x78, 0x28, 0x47, 0x77, 0x24, 0xA1, 0x3C, 0xC3, // x(Gw$.<.
/* 00B8 */ 0xB6, 0x11, 0x84, 0x71, 0x2A, 0x71, 0xCE, 0x3A, // ...q*q.:
/* 00C0 */ 0xCA, 0xF1, 0x9C, 0x9A, 0xA7, 0x73, 0x4C, 0x07, // .....sL.
/* 00C8 */ 0x74, 0x48, 0x46, 0x39, 0x6E, 0xE0, 0x32, 0x02, // tHF9n.2.
/* 00D0 */ 0x2E, 0xF2, 0x69, 0x60, 0x02, 0xC9, 0x3F, 0x24, // ..i`..?$
/* 00D8 */ 0x48, 0x16, 0x0C, 0x4A, 0xC2, 0xE8, 0xA9, 0x0B, // H..J....
/* 00E0 */ 0x08, 0xFD, 0xFF, 0x81, 0xF9, 0xD9, 0x80, 0x8D, // ........
/* 00E8 */ 0xC6, 0x10, 0xA5, 0x8D, 0x13, 0x3D, 0xC4, 0x53, // .....=.S
/* 00F0 */ 0x39, 0xB2, 0x13, 0x39, 0x90, 0x43, 0x63, 0xA8, // 9..9.Cc.
/* 00F8 */ 0xA7, 0x74, 0x38, 0x85, 0xDD, 0x01, 0x84, 0x1A, // .t8.....
/* 0100 */ 0xA3, 0x39, 0x28, 0x12, 0x6E, 0x7C, 0x68, 0x89, // .9(.n|h.
/* 0108 */ 0xB0, 0x3A, 0x09, 0xC4, 0x7E, 0x17, 0xB0, 0xF0, // .:..~...
/* 0110 */ 0x61, 0x09, 0xE3, 0x7C, 0x3D, 0x7C, 0x8B, 0x86, // a..|=|..
/* 0118 */ 0x11, 0x5A, 0x41, 0x70, 0x1A, 0xC4, 0x51, 0x44, // .ZAp..QD
/* 0120 */ 0x09, 0xC3, 0xF0, 0x8C, 0x19, 0xE8, 0xB9, 0x80, // ........
/* 0128 */ 0x21, 0x85, 0x09, 0x7A, 0x02, 0x41, 0xCE, 0x93, // !..z.A..
/* 0130 */ 0x61, 0x19, 0xE2, 0x0C, 0x38, 0x56, 0x8C, 0x50, // a...8V.P
/* 0138 */ 0x21, 0x31, 0x03, 0x09, 0x7E, 0x02, 0x5D, 0x63, // !1..~.]c
/* 0140 */ 0xC8, 0x33, 0x10, 0x99, 0xF2, 0x09, 0x04, 0x89, // .3......
/* 0148 */ 0x1E, 0x25, 0xB8, 0x71, 0x8D, 0xCA, 0xC6, 0x74, // .%.q...t
/* 0150 */ 0x36, 0xB8, 0x81, 0x99, 0x20, 0xCE, 0xE1, 0x61, // 6... ..a
/* 0158 */ 0x64, 0x40, 0x68, 0x02, 0xF1, 0x63, 0x87, 0x4F, // d@h..c.O
/* 0160 */ 0x60, 0xF7, 0x02, 0xBC, 0x0D, 0x51, 0x10, 0x95, // `....Q..
/* 0168 */ 0xDD, 0x35, 0xA4, 0x0D, 0x42, 0x28, 0x6D, 0x09, // .5..B(m.
/* 0170 */ 0xB0, 0x36, 0x59, 0x9D, 0x08, 0x5E, 0x08, 0xA2, // .6Y..^..
/* 0178 */ 0x1C, 0x6F, 0x84, 0x67, 0x82, 0x10, 0x51, 0x02, // .o.g..Q.
/* 0180 */ 0x45, 0xA8, 0x10, 0x53, 0x28, 0x71, 0x1B, 0x13, // E..S(q..
/* 0188 */ 0xA0, 0x11, 0x42, 0x48, 0x86, 0x0B, 0xE1, 0x79, // ..BH...y
/* 0190 */ 0x87, 0xB1, 0xFD, 0x41, 0x90, 0x60, 0xE7, 0x01, // ...A.`..
/* 0198 */ 0xFD, 0x08, 0x2C, 0x09, 0x44, 0x46, 0xB6, 0x94, // ..,.DF..
/* 01A0 */ 0x80, 0x9C, 0x14, 0x3C, 0x1C, 0x0F, 0xA0, 0xF9, // ...<....
/* 01A8 */ 0x99, 0x69, 0x54, 0x4C, 0x02, 0xA0, 0x34, 0x80, // .iTL..4.
/* 01B0 */ 0x48, 0xD4, 0x59, 0x84, 0x12, 0x58, 0xCA, 0xC9, // H.Y..X..
/* 01B8 */ 0x80, 0x5C, 0x1F, 0x3C, 0x92, 0x03, 0x3C, 0x75, // .\.<..<u
/* 01C0 */ 0xDF, 0x0D, 0xCE, 0xCC, 0x5F, 0x13, 0x6F, 0xC1, // ...._.o.
/* 01C8 */ 0x67, 0x04, 0x3E, 0x06, 0x0F, 0xF5, 0x10, 0x02, // g.>.....
/* 01D0 */ 0x1E, 0x21, 0x3B, 0x24, 0x18, 0x10, 0xEF, 0xFD, // .!;$....
/* 01D8 */ 0x56, 0x40, 0xE6, 0x62, 0x82, 0xFF, 0x7F, 0x40, // V@.b...@
/* 01E0 */ 0x1F, 0x14, 0x9E, 0x0F, 0xC0, 0x32, 0xCC, 0x53, // .....2.S
/* 01E8 */ 0xF6, 0x1C, 0x2A, 0x1E, 0x1B, 0xE2, 0x4A, 0xC0, // ..*...J.
/* 01F0 */ 0xC7, 0x72, 0x54, 0xEC, 0x18, 0xC1, 0x46, 0xC7, // .rT...F.
/* 01F8 */ 0x47, 0xE1, 0xB3, 0xC3, 0xF9, 0x16, 0x0B, 0xA2, // G.......
/* 0200 */ 0x00, 0x10, 0x92, 0x75, 0x8C, 0x40, 0xCF, 0xFB, // ...u.@..
/* 0208 */ 0x08, 0x03, 0xBE, 0x34, 0x34, 0x7B, 0x39, 0x21, // ...44{9!
/* 0210 */ 0x04, 0xAF, 0x03, 0xBE, 0x31, 0xF8, 0x1C, 0x63, // ....1..c
/* 0218 */ 0x79, 0x07, 0x11, 0x10, 0xC1, 0xBF, 0x2F, 0xE0, // y...../.
/* 0220 */ 0x8E, 0x20, 0xC0, 0x49, 0xEA, 0xF9, 0x03, 0x25, // . .I...%
/* 0228 */ 0xEE, 0x08, 0x02, 0xE8, 0xFC, 0xFF, 0x1F, 0x41, // .......A
/* 0230 */ 0x80, 0x25, 0xC8, 0xA1, 0xBC, 0x3F, 0x84, 0x78, // .%...?.x
/* 0238 */ 0x7D, 0x38, 0xD5, 0x57, 0x90, 0xC8, 0xEF, 0x1F, // }8.W....
/* 0240 */ 0xC6, 0x8F, 0x12, 0x28, 0x8A, 0xD1, 0x1E, 0x20, // ...(...
/* 0248 */ 0x8C, 0x12, 0x27, 0xC2, 0x19, 0x3F, 0x82, 0xD8, // ..'..?..
/* 0250 */ 0xD9, 0x59, 0x44, 0x10, 0x3E, 0x14, 0xF8, 0x32, // .YD.>..2
/* 0258 */ 0xF2, 0xE0, 0xE3, 0x53, 0x43, 0x90, 0xA0, 0x8F, // ...SC...
/* 0260 */ 0x20, 0x2C, 0xDE, 0x11, 0x04, 0xD0, 0x37, 0xC6, // ,....7.
/* 0268 */ 0xE3, 0x7C, 0x03, 0x81, 0x7D, 0x04, 0x81, 0x79, // .|..}..y
/* 0270 */ 0xDC, 0xF0, 0x11, 0x04, 0x5C, 0x67, 0x0E, 0xDC, // ....\g..
/* 0278 */ 0x11, 0x04, 0xCE, 0xFF, 0xFF, 0x08, 0x82, 0x19, // ........
/* 0280 */ 0xD4, 0xF9, 0x78, 0x52, 0x1E, 0xDC, 0x69, 0xBD, // ..xR..i.
/* 0288 */ 0x85, 0xE0, 0x4F, 0x21, 0xC0, 0x27, 0x8B, 0x17, // ..O!.'..
/* 0290 */ 0x10, 0x16, 0xE7, 0x39, 0xA0, 0x78, 0x4B, 0xA5, // ...9.xK.
/* 0298 */ 0x30, 0xF6, 0x70, 0x0A, 0x81, 0x2E, 0x09, 0x0E, // 0.p.....
/* 02A0 */ 0x35, 0x48, 0x9F, 0x04, 0x8E, 0xED, 0x58, 0x4F, // 5H....XO
/* 02A8 */ 0xE4, 0x25, 0xC1, 0x83, 0x7B, 0x1C, 0x81, 0x71, // .%..{..q
/* 02B0 */ 0x58, 0xF0, 0xB4, 0x4E, 0xCA, 0x57, 0x31, 0x0F, // X..N.W1.
/* 02B8 */ 0xCA, 0x30, 0x09, 0x3C, 0x0A, 0x86, 0xC6, 0x4F, // .0.<...O
/* 02C0 */ 0x01, 0xEC, 0x30, 0xC0, 0x07, 0xEA, 0x93, 0x03, // ..0.....
/* 02C8 */ 0xBB, 0xBC, 0xF9, 0x7A, 0xF0, 0xE2, 0xE6, 0xA3, // ...z....
/* 02D0 */ 0x86, 0xBF, 0x7D, 0xFC, 0xBC, 0x86, 0x3B, 0x2A, // ..}...;*
/* 02D8 */ 0xC0, 0x3D, 0x06, 0xB0, 0x63, 0x42, 0xE0, 0x83, // .=..cB..
/* 02E0 */ 0xF6, 0x84, 0x5F, 0x15, 0x3C, 0x1C, 0x06, 0xF2, // .._.<...
/* 02E8 */ 0xBE, 0x86, 0x3F, 0x80, 0xE0, 0x3D, 0x1E, 0xF1, // ..?..=..
/* 02F0 */ 0x04, 0x7A, 0x1A, 0x8F, 0x54, 0xFC, 0x98, 0xF1, // .z..T...
/* 02F8 */ 0xE2, 0x12, 0x27, 0xC4, 0x8B, 0xC0, 0x83, 0x54, // ..'....T
/* 0300 */ 0x8C, 0x47, 0x2A, 0xE3, 0x3C, 0x80, 0xC4, 0x79, // .G*.<..y
/* 0308 */ 0x00, 0xF1, 0x1D, 0xE2, 0xED, 0xE3, 0xA5, 0xCA, // ........
/* 0310 */ 0x37, 0x2B, 0x9F, 0x08, 0xA2, 0xBD, 0x54, 0x19, // 7+....T.
/* 0318 */ 0x2A, 0xCC, 0xC3, 0x47, 0xB0, 0xE0, 0x41, 0x5E, // *..G..A^
/* 0320 */ 0x42, 0xE2, 0xC4, 0x7C, 0x0D, 0xF1, 0x01, 0x84, // B..|....
/* 0328 */ 0x0D, 0x1C, 0xF7, 0xFF, 0x3F, 0xD6, 0x80, 0x47, // ....?..G
/* 0330 */ 0xD0, 0x6B, 0x4F, 0x16, 0x0E, 0x7C, 0x14, 0x9E, // .kO..|..
/* 0338 */ 0x9F, 0x18, 0x7C, 0x36, 0xF0, 0xD0, 0x0E, 0xDC, // ..|6....
/* 0340 */ 0xD7, 0x0B, 0x83, 0x9C, 0xA3, 0x4F, 0x0D, 0x0F, // .....O..
/* 0348 */ 0x05, 0x1E, 0x03, 0xBB, 0x2D, 0xF8, 0x18, 0xE0, // ....-...
/* 0350 */ 0x53, 0x02, 0xFE, 0x1A, 0x11, 0xF0, 0xF5, 0xE0, // S.......
/* 0358 */ 0x31, 0x04, 0xD6, 0x71, 0x04, 0x3F, 0xA2, 0x87, // 1..q.?..
/* 0360 */ 0x0D, 0xD8, 0xE3, 0xF1, 0x2D, 0x91, 0x9D, 0x2D, // ....-..-
/* 0368 */ 0x9E, 0x8B, 0xC8, 0x20, 0x50, 0x23, 0x33, 0xB4, // ... P#3.
/* 0370 */ 0x27, 0x7D, 0x5A, 0xAF, 0x05, 0x3E, 0x2C, 0x9A, // '}Z..>,.
/* 0378 */ 0xC0, 0x67, 0x10, 0x1F, 0x11, 0x3D, 0x1E, 0xF0, // .g...=..
/* 0380 */ 0xDF, 0x3E, 0x9E, 0x13, 0x18, 0xB6, 0x4F, 0x0B, // .>....O.
/* 0388 */ 0xC6, 0x7A, 0x6C, 0x04, 0xD3, 0xB1, 0x01, 0x73, // .zl....s
/* 0390 */ 0x6B, 0x84, 0x79, 0x1C, 0x01, 0x1E, 0x82, 0x0F, // k.y.....
/* 0398 */ 0x9F, 0xD0, 0xFE, 0xFF, 0x87, 0x4F, 0x78, 0xE7, // .....Ox.
/* 03A0 */ 0x4B, 0xF0, 0x65, 0x74, 0x72, 0x16, 0x62, 0xA9, // K.etr.b.
/* 03A8 */ 0x5F, 0x01, 0xB2, 0x71, 0x2A, 0xA2, 0xA7, 0x10, // _..q*...
/* 03B0 */ 0x6B, 0x02, 0xD2, 0x18, 0xD8, 0x25, 0x84, 0xA3, // k....%..
/* 03B8 */ 0x1C, 0x85, 0x0F, 0x36, 0x1E, 0x9C, 0x07, 0x76, // ...6...v
/* 03C0 */ 0x40, 0x21, 0x02, 0xF9, 0x7C, 0xC0, 0xD2, 0x3F, // @!..|..?
/* 03C8 */ 0x44, 0x74, 0x12, 0xF1, 0xB9, 0xC0, 0xB9, 0x49, // Dt.....I
/* 03D0 */ 0x94, 0x7C, 0x6C, 0x14, 0xCE, 0x59, 0x0F, 0x24, // .|l..Y.$
/* 03D8 */ 0x14, 0xC4, 0x80, 0x0E, 0x02, 0xA1, 0xDD, 0xE8, // ........
/* 03E0 */ 0xA8, 0x80, 0x38, 0xAB, 0xF8, 0x84, 0xE5, 0x61, // ..8....a
/* 03E8 */ 0x3C, 0x50, 0xB0, 0x33, 0x0E, 0x23, 0x78, 0xBA, // <P.3.#x.
/* 03F0 */ 0x7A, 0xA2, 0x60, 0x07, 0x00, 0x9F, 0x15, 0xF8, // z.`.....
/* 03F8 */ 0xD8, 0x7C, 0x79, 0x30, 0xBA, 0xD5, 0x9C, 0x57, // .|y0...W
/* 0400 */ 0x50, 0x60, 0x3E, 0x8E, 0x70, 0x82, 0xBA, 0xAE, // P`>.p...
/* 0408 */ 0x42, 0xA0, 0x39, 0x88, 0x3C, 0x87, 0x24, 0xA8, // B.9.<.$.
/* 0410 */ 0xEF, 0xBC, 0x00, 0x0A, 0x20, 0x5F, 0x0E, 0x7C, // .... _.|
/* 0418 */ 0x18, 0x78, 0x40, 0x60, 0x63, 0x78, 0x1E, 0x30, // .x@`cx.0
/* 0420 */ 0x9A, 0xD1, 0x79, 0xF8, 0xC9, 0xA2, 0xEE, 0xC2, // ..y.....
/* 0428 */ 0x9E, 0xAC, 0x41, 0x3C, 0x59, 0x47, 0x99, 0x2C, // ..A<YG.,
/* 0430 */ 0x7A, 0x26, 0xBE, 0x5C, 0x78, 0x42, 0xA7, 0x14, // z&.\xB..
/* 0438 */ 0xE4, 0x1C, 0x3D, 0x61, 0x5F, 0x46, 0x60, 0x9D, // ..=a_F`.
/* 0440 */ 0x04, 0x42, 0x3E, 0x33, 0x78, 0x1A, 0xBE, 0x47, // .B>3x..G
/* 0448 */ 0x61, 0xFE, 0xFF, 0x70, 0x6C, 0xB2, 0x7C, 0x2C, // a..pl.|,
/* 0450 */ 0xBE, 0x6C, 0xC0, 0x1F, 0x2D, 0x96, 0xA0, 0xC0, // .l..-...
/* 0458 */ 0xD9, 0x82, 0x1C, 0x1E, 0x13, 0x6C, 0x54, 0xF4, // .....lT.
/* 0460 */ 0xF6, 0xE0, 0xE1, 0xF1, 0xCB, 0x81, 0xE7, 0xF3, // ........
/* 0468 */ 0x8C, 0x70, 0x94, 0x2F, 0x22, 0x3E, 0x25, 0x78, // .p./">%x
/* 0470 */ 0x3A, 0x3E, 0xD5, 0x79, 0x88, 0xEC, 0x76, 0x04, // :>.y..v.
/* 0478 */ 0x6B, 0x22, 0x27, 0xED, 0xDB, 0xC2, 0xC9, 0x06, // k"'.....
/* 0480 */ 0x7D, 0x4F, 0xC3, 0x5C, 0x4B, 0x70, 0xB7, 0x23, // }O.\Kp.#
/* 0488 */ 0xB8, 0xD3, 0x3A, 0xBD, 0x57, 0x40, 0xCC, 0xC9, // ..:.W@..
/* 0490 */ 0x82, 0x01, 0xBD, 0x60, 0x1C, 0xEE, 0x7B, 0x8E, // ...`..{.
/* 0498 */ 0x41, 0x31, 0xE1, 0x57, 0xA1, 0xAB, 0x06, 0x1F, // A1.W....
/* 04A0 */ 0x84, 0xA5, 0x01, 0xE9, 0xAA, 0xC1, 0x4E, 0x30, // ......N0
/* 04A8 */ 0x7C, 0x68, 0x3E, 0xF1, 0x31, 0x39, 0xB7, 0x0C, // |h>.19..
/* 04B0 */ 0x0A, 0x61, 0x21, 0x14, 0x92, 0x01, 0xA1, 0x93, // .a!.....
/* 04B8 */ 0x02, 0x0F, 0x0E, 0x46, 0x41, 0x7C, 0x52, 0x70, // ...FA|Rp
/* 04C0 */ 0x28, 0x08, 0xD9, 0x38, 0x29, 0x40, 0x8F, 0x70, // (..8)@.p
/* 04C8 */ 0x52, 0x00, 0x35, 0x81, 0x51, 0x3C, 0x66, 0xF6, // R.5.Q<f.
/* 04D0 */ 0xFF, 0x3F, 0x29, 0xC0, 0x1A, 0xC2, 0x63, 0x4E, // .?)...cN
/* 04D8 */ 0xD5, 0xA3, 0xD1, 0x60, 0xAD, 0xEE, 0x28, 0x0A, // ...`..(.
/* 04E0 */ 0xED, 0xB8, 0x00, 0x38, 0x3A, 0x04, 0xF8, 0xB8, // ...8:...
/* 04E8 */ 0x00, 0x9E, 0xDB, 0x01, 0xFF, 0x24, 0x3C, 0x1E, // .....$<.
/* 04F0 */ 0xF0, 0xDB, 0x02, 0x1C, 0x82, 0xD1, 0x7F, 0xAB, // ........
/* 04F8 */ 0x3A, 0x2E, 0xF0, 0xE1, 0x5A, 0x1A, 0x90, 0x26, // :...Z..&
/* 0500 */ 0xCE, 0x2E, 0x91, 0xFC, 0x66, 0x27, 0x28, 0xDD, // ....f'(.
/* 0508 */ 0x70, 0xB8, 0x18, 0x18, 0xC9, 0x59, 0x9B, 0x0E, // p....Y..
/* 0510 */ 0x0B, 0x7C, 0x79, 0x86, 0x33, 0x88, 0xEF, 0x32, // .|y.3..2
/* 0518 */ 0x4E, 0x71, 0x4A, 0x41, 0xEB, 0xB8, 0x2D, 0x91, // NqJA..-.
/* 0520 */ 0xB9, 0xBC, 0x65, 0x79, 0x86, 0xEF, 0x28, 0x3E, // ..ey..(>
/* 0528 */ 0xE0, 0x00, 0xB7, 0xFF, 0xFF, 0x19, 0x05, 0x97, // ........
/* 0530 */ 0x63, 0x4A, 0x68, 0x25, 0xC8, 0xE4, 0x42, 0x10, // cJh%..B.
/* 0538 */ 0xF2, 0x81, 0x80, 0xCD, 0x09, 0xDC, 0x93, 0xF5, // ........
/* 0540 */ 0x9C, 0xC0, 0x76, 0x4F, 0x82, 0x73, 0xB5, 0xC3, // ..vO.s..
/* 0548 */ 0x80, 0xBF, 0xCF, 0xFA, 0x4E, 0x71, 0x50, 0xE0, // ....NqP.
/* 0550 */ 0xBD, 0x16, 0x78, 0x50, 0x60, 0x8B, 0x71, 0x1E, // ..xP`.q.
/* 0558 */ 0x82, 0x72, 0x33, 0x7C, 0x59, 0xF0, 0xBC, 0x1F, // .r3|Y...
/* 0560 */ 0x28, 0x82, 0xBC, 0xE3, 0x79, 0x4C, 0x60, 0x45, // (...yL`E
/* 0568 */ 0xF2, 0x98, 0xC0, 0x96, 0x61, 0x4C, 0x68, 0x15, // ....aLh.
/* 0570 */ 0x47, 0x0D, 0x32, 0xEE, 0x27, 0x8C, 0xF7, 0x15, // G.2.'...
/* 0578 */ 0xCF, 0x08, 0x5C, 0xFF, 0xFF, 0x19, 0x61, 0xEE, // ..\...a.
/* 0580 */ 0xD8, 0x3E, 0x6C, 0x01, 0xBE, 0x2F, 0x99, 0x3E, // .>l../.>
/* 0588 */ 0x6C, 0x01, 0xEF, 0x58, 0xC7, 0x1D, 0xA0, 0x06, // l..X....
/* 0590 */ 0xE9, 0x3B, 0x35, 0x58, 0xFE, 0xFF, 0x37, 0x5B, // .;5X..7[
/* 0598 */ 0xCC, 0xFD, 0x86, 0xDF, 0x76, 0xE0, 0xC8, 0xB8, // ....v...
/* 05A0 */ 0x25, 0xA2, 0x38, 0x2C, 0xF3, 0xAC, 0x05, 0xE1, // %.8,....
/* 05A8 */ 0xFE, 0x8C, 0xBD, 0x2F, 0x92, 0xD3, 0x16, 0x4A, // .../...J
/* 05B0 */ 0x10, 0x85, 0x4E, 0x5C, 0x3E, 0xF1, 0x20, 0xE0, // ..N\>. .
/* 05B8 */ 0x28, 0x85, 0x8F, 0x0A, 0xBE, 0xED, 0xFB, 0xB4, // (.......
/* 05C0 */ 0x05, 0xFF, 0xCC, 0xE0, 0xD3, 0x16, 0xB8, 0x6F, // .......o
/* 05C8 */ 0xC7, 0xB8, 0xD3, 0x16, 0x78, 0x4E, 0xDD, 0xB0, // ....xN..
/* 05D0 */ 0xCF, 0x0C, 0x80, 0xA5, 0x63, 0x8A, 0xCF, 0x0C, // ....c...
/* 05D8 */ 0x30, 0xFF, 0xFF, 0x27, 0x2E, 0x78, 0xD3, 0xC5, // 0..'.x..
/* 05E0 */ 0x02, 0x3D, 0x71, 0x78, 0xD2, 0x31, 0x13, 0x54, // .=qx.1.T
/* 05E8 */ 0xF1, 0xFA, 0xD0, 0x99, 0x81, 0x8B, 0x82, 0x90, // ........
/* 05F0 */ 0xBA, 0x03, 0x17, 0x62, 0x42, 0xEC, 0xD6, 0x8F, // ...bB...
/* 05F8 */ 0x39, 0xB8, 0x3E, 0x93, 0x1A, 0x26, 0xC6, 0x39, // 9.>..&.9
/* 0600 */ 0x3C, 0x47, 0x33, 0x25, 0xC7, 0x2E, 0x94, 0x06, // <G3%....
/* 0608 */ 0x18, 0xA9, 0x38, 0x76, 0xA1, 0x72, 0x53, 0x09, // ..8v.rS.
/* 0610 */ 0xCE, 0x20, 0xBE, 0xD5, 0x38, 0xC4, 0x79, 0x05, // . ..8.y.
/* 0618 */ 0x7D, 0x2F, 0xF6, 0x71, 0xE0, 0x9D, 0xC4, 0x03, // }/.q....
/* 0620 */ 0x7B, 0xCD, 0x7E, 0xEB, 0x02, 0xA6, 0x43, 0x82, // {.~...C.
/* 0628 */ 0x0B, 0xE8, 0x43, 0x17, 0xF0, 0x1C, 0x12, 0x5C, // ..C....\
/* 0630 */ 0xC4, 0x43, 0x02, 0xEF, 0xFF, 0xFF, 0xC8, 0x05, // .C......
/* 0638 */ 0xC6, 0x21, 0xC1, 0xBD, 0xC6, 0xFB, 0xC4, 0x05, // .!......
/* 0640 */ 0x3C, 0x87, 0x04, 0xF7, 0x3A, 0xF1, 0xC6, 0x05, // <...:...
/* 0648 */ 0xF0, 0xE4, 0xFF, 0x7F, 0xE3, 0x02, 0xFE, 0xF1, // ........
/* 0650 */ 0xAE, 0x3B, 0x40, 0x6D, 0x98, 0x3E, 0xF3, 0xBF, // .;@m.>..
/* 0658 */ 0xEE, 0x80, 0xEF, 0x80, 0x83, 0x81, 0xA9, 0x70, // .......p
/* 0660 */ 0x0A, 0xF2, 0x39, 0x39, 0xA1, 0x3C, 0xE3, 0xC0, // ..99.<..
/* 0668 */ 0x20, 0x98, 0xF4, 0xD6, 0x85, 0x92, 0x04, 0x21, // ......!
/* 0670 */ 0x35, 0x67, 0x7D, 0xF4, 0x58, 0x8F, 0x82, 0xCD, // 5g}.X...
/* 0678 */ 0xD7, 0xC3, 0x79, 0x76, 0x3C, 0xE6, 0x73, 0x30, // ..yv<.s0
/* 0680 */ 0xC1, 0xEC, 0x27, 0x7D, 0x54, 0x6A, 0x12, 0xE5, // ..'}Tj..
/* 0688 */ 0x3E, 0x2F, 0xA0, 0x92, 0x9E, 0x17, 0x28, 0x88, // >/....(.
/* 0690 */ 0x01, 0x7D, 0x9B, 0x84, 0x73, 0xD3, 0x38, 0xBD, // .}..s.8.
/* 0698 */ 0xC3, 0x63, 0xB7, 0x82, 0x43, 0x79, 0xE5, 0x01, // .c..Cy..
/* 06A0 */ 0xFB, 0xFF, 0xFF, 0xA0, 0x0F, 0x30, 0x2D, 0xD2, // .....0-.
/* 06A8 */ 0x55, 0x03, 0xA8, 0xDD, 0x12, 0x7C, 0x4A, 0xC7, // U....|J.
/* 06B0 */ 0x5D, 0x35, 0xE0, 0xDE, 0x29, 0xD8, 0xEF, 0xE2, // ]5..)...
/* 06B8 */ 0x65, 0x83, 0xFD, 0xFF, 0x2F, 0x1B, 0xBE, 0x56, // e.../..V
/* 06C0 */ 0x60, 0x62, 0xFE, 0x77, 0x4C, 0xA0, 0x38, 0x4B, // `b.wL.8K
/* 06C8 */ 0x57, 0x30, 0x18, 0xD4, 0x40, 0x7C, 0x18, 0xC0, // W0..@|..
/* 06D0 */ 0x8F, 0xE9, 0x10, 0x62, 0x1F, 0x1A, 0xBB, 0x6F, // ...b...o
/* 06D8 */ 0x18, 0x8E, 0x8F, 0xDC, 0x03, 0x79, 0x7A, 0x3B, // .....yz;
/* 06E0 */ 0x96, 0xF3, 0x38, 0x37, 0x4F, 0x28, 0x24, 0x3B, // ..87O($;
/* 06E8 */ 0x37, 0x79, 0x60, 0xFC, 0x8C, 0xEC, 0xD1, 0x9C, // 7y`.....
/* 06F0 */ 0xD0, 0x49, 0x3D, 0x86, 0x3C, 0x1C, 0xF9, 0x26, // .I=.<..&
/* 06F8 */ 0x67, 0x02, 0x0F, 0x94, 0xA1, 0x71, 0x82, 0x01, // g....q..
/* 0700 */ 0x46, 0x09, 0x9A, 0x9B, 0xB5, 0x0F, 0xCD, 0x46, // F......F
/* 0708 */ 0x38, 0xC7, 0x78, 0xA1, 0x7C, 0xC5, 0xF4, 0x11, // 8.x.|...
/* 0710 */ 0xC1, 0x10, 0x3E, 0x7C, 0x3C, 0xA5, 0x7B, 0x10, // ..>|<.{.
/* 0718 */ 0xEF, 0x01, 0x0C, 0xE6, 0xFD, 0xD0, 0x28, 0x47, // ......(G
/* 0720 */ 0xE3, 0xFB, 0x31, 0x1B, 0xB1, 0xAD, 0x9E, 0xA3, // ..1.....
/* 0728 */ 0x09, 0x2C, 0x03, 0x7A, 0x44, 0xE7, 0xA3, 0xC3, // .,.zD...
/* 0730 */ 0x0D, 0xD3, 0x07, 0x6A, 0xCC, 0x85, 0x85, 0x4D, // ...j...M
/* 0738 */ 0xF8, 0x49, 0xE1, 0x45, 0xE6, 0x25, 0xA2, 0x78, // .I.E.%.x
/* 0740 */ 0x54, 0x61, 0x34, 0x07, 0x45, 0xE0, 0x42, 0x63, // Ta4.E.Bc
/* 0748 */ 0x4E, 0x55, 0x38, 0x02, 0xBB, 0x17, 0x20, 0xEE, // NU8... .
/* 0750 */ 0x18, 0xA1, 0x19, 0xF6, 0x06, 0xA1, 0x73, 0x4C, // ......sL
/* 0758 */ 0xE4, 0x47, 0xBC, 0xB6, 0x80, 0x34, 0xBF, 0xDA, // .G...4..
/* 0760 */ 0x80, 0x84, 0x72, 0x04, 0x2F, 0x13, 0x41, 0xE2, // ..r./.A.
/* 0768 */ 0x44, 0x09, 0xF7, 0x66, 0x10, 0x2E, 0x46, 0x94, // D..f..F.
/* 0770 */ 0xD6, 0xE0, 0x08, 0x4E, 0x84, 0x28, 0x07, 0x12, // ...N.(..
/* 0778 */ 0xBC, 0x46, 0x48, 0x81, 0x85, 0x68, 0xFF, 0x08, // .FH..h..
/* 0780 */ 0xC0, 0x4E, 0xF0, 0xF4, 0x1C, 0xE1, 0xD1, 0xF0, // .N......
/* 0788 */ 0x83, 0x85, 0xCF, 0x06, 0x3E, 0x17, 0x9C, 0xE3, // ....>...
/* 0790 */ 0x13, 0xBC, 0xE7, 0xF6, 0x8C, 0xEA, 0xC1, 0xD5, // ........
/* 0798 */ 0x79, 0x28, 0x20, 0xC3, 0x63, 0x47, 0x0F, 0x9F, // y( .cG..
/* 07A0 */ 0x40, 0xD8, 0xFF, 0xFF, 0x94, 0x80, 0x3D, 0x67, // @.....=g
/* 07A8 */ 0x06, 0x7C, 0x3F, 0xF5, 0xE1, 0xC0, 0xCF, 0x1C, // .|?.....
/* 07B0 */ 0xC3, 0xF1, 0x21, 0xFA, 0xF0, 0xC0, 0x47, 0xC2, // ..!...G.
/* 07B8 */ 0x8E, 0x20, 0x60, 0x18, 0x8F, 0x8F, 0x06, 0x3E, // . `....>
/* 07C0 */ 0x05, 0x98, 0xC0, 0xF2, 0x07, 0x81, 0x3A, 0xA7, // ......:.
/* 07C8 */ 0xF0, 0x59, 0xBE, 0xC9, 0xB2, 0x73, 0x81, 0x09, // .Y...s..
/* 07D0 */ 0x2C, 0xF6, 0xC8, 0x42, 0xC7, 0x03, 0xFE, 0x93, // ,..B....
/* 07D8 */ 0xD1, 0xA3, 0x41, 0x84, 0x37, 0x03, 0xCF, 0xD7, // ..A.7...
/* 07E0 */ 0xE7, 0x59, 0x76, 0x8C, 0xC1, 0x9D, 0x21, 0x3C, // .Yv...!<
/* 07E8 */ 0xE8, 0x88, 0xC7, 0xE3, 0xC3, 0xD1, 0xC9, 0xD6, // ........
/* 07F0 */ 0x7A, 0x4A, 0x20, 0x47, 0x83, 0x33, 0x72, 0xF0, // zJ G.3r.
/* 07F8 */ 0xEB, 0x13, 0x3D, 0x67, 0xFA, 0x3C, 0xC2, 0x0F, // ..=g.<..
/* 0800 */ 0x17, 0x3E, 0x57, 0xB0, 0x9B, 0x2F, 0x3F, 0x8E, // .>W../?.
/* 0808 */ 0xB0, 0x73, 0x2E, 0x19, 0x1B, 0x74, 0x40, 0xFC, // .s...t@.
/* 0810 */ 0x41, 0x0A, 0x03, 0xC8, 0x26, 0xF7, 0xA4, 0x01, // A...&...
/* 0818 */ 0x96, 0xC1, 0x61, 0x4E, 0x21, 0x9E, 0x91, 0xD1, // ..aN!...
/* 0820 */ 0xD8, 0xB9, 0x8A, 0xCD, 0x8F, 0x1F, 0x74, 0xC0, // ......t.
/* 0828 */ 0xF7, 0xFF, 0x3F, 0xBE, 0x60, 0x0F, 0x3A, 0xF0, // ..?.`.:.
/* 0830 */ 0x6E, 0x59, 0x0C, 0xEA, 0x00, 0xDE, 0x40, 0xF8, // nY....@.
/* 0838 */ 0xE1, 0x03, 0x43, 0x60, 0x91, 0x23, 0x44, 0x8F, // ..C`.#D.
/* 0840 */ 0x80, 0x8F, 0xEE, 0xA1, 0x87, 0x8D, 0xE0, 0xBD, // ........
/* 0848 */ 0xC7, 0x93, 0x38, 0x20, 0x9F, 0x53, 0x3C, 0x45, // ..8 .S<E
/* 0850 */ 0x1F, 0x3F, 0x1E, 0x57, 0x3C, 0x8C, 0xE3, 0x3B, // .?.W<..;
/* 0858 */ 0xA9, 0xF3, 0x7B, 0xA9, 0xF0, 0x98, 0xB0, 0xE7, // ..{.....
/* 0860 */ 0x0A, 0x0F, 0x81, 0x0F, 0xE0, 0x60, 0xCE, 0xCF, // .....`..
/* 0868 */ 0xA7, 0xA0, 0xB3, 0xC2, 0x9D, 0x0A, 0xF8, 0xAC, // ........
/* 0870 */ 0x30, 0x87, 0x21, 0x5C, 0xE0, 0xF7, 0x8F, 0x8F, // 0.!\....
/* 0878 */ 0x13, 0x7E, 0x19, 0x48, 0xDE, 0x13, 0x81, 0xC2, // .~.H....
/* 0880 */ 0xF8, 0x8C, 0x03, 0xBC, 0xCF, 0x30, 0xE0, 0x14, // .....0..
/* 0888 */ 0x7C, 0x42, 0x07, 0xD9, 0xD0, 0xDF, 0x9A, 0x3C, // |B.....<
/* 0890 */ 0x20, 0x4F, 0xE7, 0x30, 0x0C, 0xF4, 0xAA, 0xC0, // O.0....
/* 0898 */ 0x90, 0x7C, 0x14, 0xF0, 0x8D, 0xC5, 0x07, 0x1F, // .|......
/* 08A0 */ 0x9F, 0x7D, 0xF8, 0xD9, 0xC6, 0xFF, 0xFF, 0xB3, // .}......
/* 08A8 */ 0x0D, 0xDC, 0xBB, 0x4C, 0x04, 0xDF, 0x65, 0x5E, // ...L..e^
/* 08B0 */ 0x67, 0x4E, 0xEA, 0x49, 0xE0, 0xE1, 0xE1, 0x9D, // gN.I....
/* 08B8 */ 0xE6, 0x80, 0x22, 0xF8, 0x62, 0x63, 0xA4, 0x37, // ..".bc.7
/* 08C0 */ 0x1A, 0xA3, 0xF8, 0x92, 0x13, 0x25, 0x44, 0x84, // .....%D.
/* 08C8 */ 0x28, 0xAF, 0x36, 0x31, 0x9E, 0x0B, 0x62, 0x05, // (.61..b.
/* 08D0 */ 0x89, 0x11, 0xC9, 0xC8, 0xD1, 0xE3, 0x1E, 0xE3, // ........
/* 08D8 */ 0xB3, 0x0D, 0x0B, 0x78, 0x1E, 0xD0, 0x27, 0xCA, // ...x..'.
/* 08E0 */ 0x67, 0x1B, 0x80, 0x1F, 0x87, 0x16, 0xDC, 0xA1, // g.......
/* 08E8 */ 0x04, 0xFE, 0x61, 0x01, 0x0C, 0xE7, 0x12, 0xF8, // ..a.....
/* 08F0 */ 0xFF, 0xFF, 0x73, 0x09, 0x98, 0x82, 0x98, 0x3A, // ..s....:
/* 08F8 */ 0x01, 0x31, 0x21, 0xB7, 0x4D, 0xD4, 0x20, 0x2C, // .1!.M. ,
/* 0900 */ 0xF7, 0x98, 0xA0, 0x0B, 0xDC, 0x4B, 0x9D, 0x6F, // .....K.o
/* 0908 */ 0x40, 0xA7, 0xE3, 0x33, 0xC0, 0x5B, 0x05, 0x3F, // @..3.[.?
/* 0910 */ 0x5C, 0xE8, 0xAA, 0x49, 0x21, 0x2C, 0x8E, 0x42, // \..I!,.B
/* 0918 */ 0xD2, 0x20, 0x74, 0x5E, 0xE4, 0x62, 0xE0, 0x28, // . t^.b.(
/* 0920 */ 0x88, 0x8F, 0x00, 0x0E, 0x7A, 0x48, 0x86, 0x72, // ....zH.r
/* 0928 */ 0x17, 0xE2, 0x04, 0x0E, 0x76, 0x2F, 0xA6, 0xC7, // ....v/..
/* 0930 */ 0x45, 0xB8, 0x67, 0x43, 0xDC, 0xE1, 0x03, 0xEE, // E.gC....
/* 0938 */ 0xE0, 0xE0, 0x1D, 0x1F, 0xE1, 0x1D, 0x83, 0xC0, // ........
/* 0940 */ 0x71, 0xB1, 0x09, 0xF4, 0x14, 0x10, 0xE8, 0xF1, // q.......
/* 0948 */ 0x11, 0xF8, 0x04, 0x3A, 0x3E, 0xA2, 0xCE, 0x8C, // ...:>...
/* 0950 */ 0xE0, 0x38, 0x05, 0xF8, 0x24, 0x09, 0xA6, 0xFF, // .8..$...
/* 0958 */ 0xFF, 0xE8, 0x81, 0x81, 0xC0, 0x43, 0x03, 0xEA, // .....C..
/* 0960 */ 0xF4, 0xE5, 0x93, 0x90, 0x61, 0xD9, 0x34, 0x5F, // ....a.4_
/* 0968 */ 0x65, 0x0C, 0xF2, 0x08, 0x11, 0xF6, 0xC9, 0xC2, // e.......
/* 0970 */ 0xF0, 0x30, 0xA4, 0x1E, 0x1C, 0x50, 0x22, 0x29, // .0...P")
/* 0978 */ 0x74, 0x78, 0xF0, 0xC1, 0x81, 0x8B, 0x82, 0xA3, // tx......
/* 0980 */ 0x20, 0x3E, 0x38, 0x38, 0xF0, 0xC1, 0x01, 0x7A, // >88...z
/* 0988 */ 0xC0, 0x83, 0x03, 0x28, 0xCE, 0x62, 0xE0, 0x19, // ...(.b..
/* 0990 */ 0x20, 0x78, 0x0E, 0x0F, 0x80, 0x93, 0xA3, 0x87, // x......
/* 0998 */ 0x0F, 0x0F, 0x60, 0xFA, 0xFF, 0x9F, 0x03, 0xD8, // ..`.....
/* 09A0 */ 0xE1, 0x01, 0x5C, 0x27, 0x00, 0x20, 0x74, 0x80, // ..\'. t.
/* 09A8 */ 0x40, 0x1D, 0x02, 0x2C, 0xF9, 0x00, 0x81, 0x38, // @..,...8
/* 09B0 */ 0x6B, 0xBE, 0xF4, 0xF8, 0xC8, 0x79, 0xA0, 0x87, // k....y..
/* 09B8 */ 0x11, 0xE8, 0x84, 0xD8, 0xD1, 0x81, 0x9D, 0x1E, // ........
/* 09C0 */ 0xB8, 0x3C, 0x0A, 0x1D, 0x63, 0x7C, 0x7A, 0xE0, // .<..c|z.
/* 09C8 */ 0x47, 0x45, 0x83, 0x19, 0xC4, 0xC3, 0x74, 0xD4, // GE....t.
/* 09D0 */ 0xD3, 0x03, 0xF4, 0x68, 0xA7, 0x07, 0x50, 0x1C, // ...h..P.
/* 09D8 */ 0x83, 0xC1, 0x33, 0x3A, 0xB8, 0x47, 0x07, 0xC0, // ..3:.G..
/* 09E0 */ 0xC9, 0xA1, 0x9A, 0xFD, 0xFF, 0x8F, 0x0E, 0x60, // .......`
/* 09E8 */ 0x3A, 0x5F, 0x83, 0x6F, 0xF8, 0x40, 0xE2, 0xDC, // :_.o.@..
/* 09F0 */ 0x00, 0x05, 0xF1, 0xB9, 0x01, 0xD8, 0x9F, 0xC4, // ........
/* 09F8 */ 0x7C, 0x4E, 0xE3, 0x23, 0x05, 0xCF, 0xE8, 0xE0, // |N.#....
/* 0A00 */ 0x9E, 0x1B, 0x80, 0xFD, 0xFF, 0xFF, 0xDC, 0x00, // ........
/* 0A08 */ 0x2C, 0x86, 0xEE, 0x73, 0x03, 0x70, 0x1A, 0x3E, // ,..s.p.>
/* 0A10 */ 0xE4, 0xE3, 0x0B, 0xF4, 0x49, 0x3F, 0xBE, 0x00, // ....I?..
/* 0A18 */ 0xC6, 0x46, 0x87, 0x3F, 0x37, 0x00, 0xC3, 0xFF, // .F.?7...
/* 0A20 */ 0xFF, 0xB9, 0x01, 0x18, 0x9E, 0xC1, 0x7D, 0x7C, // ......}|
/* 0A28 */ 0x01, 0x7E, 0xC3, 0x87, 0x70, 0x7C, 0x81, 0x7E, // .~..p|.~
/* 0A30 */ 0x6E, 0x00, 0xCE, 0xC7, 0x17, 0xF0, 0x9F, 0x1B, // n.......
/* 0A38 */ 0x80, 0xD5, 0xFF, 0xFF, 0xDC, 0x00, 0xEC, 0xCF, // ........
/* 0A40 */ 0xE4, 0x3E, 0xBE, 0x00, 0xBF, 0xE1, 0xE3, 0x45, // .>.....E
/* 0A48 */ 0x9D, 0x1B, 0x50, 0x1C, 0x96, 0x7D, 0xB8, 0x44, // ..P..}.D
/* 0A50 */ 0xE1, 0xF7, 0x7E, 0xB0, 0x23, 0xB3, 0x3D, 0x85, // ..~.#.=.
/* 0A58 */ 0x93, 0x33, 0xD4, 0xDB, 0x4C, 0x02, 0xCB, 0x3C, // .3..L..<
/* 0A60 */ 0x38, 0xA0, 0x04, 0x1E, 0xE2, 0x7D, 0x70, 0x40, // 8....}p@
/* 0A68 */ 0x09, 0x82, 0xA3, 0x20, 0x3E, 0x38, 0x38, 0xEC, // ... >88.
/* 0A70 */ 0xC1, 0x01, 0x7A, 0xB8, 0xF3, 0x0B, 0x28, 0x4E, // ..z...(N
/* 0A78 */ 0xC7, 0xF8, 0x93, 0x20, 0xFC, 0xE1, 0xC1, 0x3B, // ... ...;
/* 0A80 */ 0x39, 0x80, 0xE1, 0xFF, 0x7F, 0x72, 0x00, 0xC6, // 9....r..
/* 0A88 */ 0xA1, 0x4E, 0x0E, 0xA0, 0xF3, 0x70, 0x72, 0x00, // .N...pr.
/* 0A90 */ 0xDD, 0xF8, 0x81, 0xC7, 0xD1, 0x01, 0xCE, 0x31, // .......1
/* 0A98 */ 0x82, 0x1D, 0x1D, 0x80, 0xFD, 0x11, 0x06, 0x37, // .......7
/* 0AA0 */ 0x56, 0xF0, 0x0C, 0x0F, 0xE6, 0xFF, 0xFF, 0xE8, // V.......
/* 0AA8 */ 0x00, 0x98, 0x04, 0xF7, 0xD1, 0x01, 0x38, 0x8D, // ......8.
/* 0AB0 */ 0x1F, 0xFE, 0x21, 0x06, 0x6C, 0x23, 0x67, 0x87, // ..!.l#g.
/* 0AB8 */ 0x18, 0xC0, 0xC4, 0xFF, 0xFF, 0xD4, 0x01, 0x9E, // ........
/* 0AC0 */ 0xE1, 0xB1, 0xA3, 0x03, 0xE0, 0xD0, 0xC4, 0x21, // .......!
/* 0AC8 */ 0x06, 0x08, 0x0F, 0x96, 0x1D, 0x62, 0xC0, 0x76, // .....b.v
/* 0AD0 */ 0x74, 0x00, 0x9E, 0xFF, 0xFF, 0x43, 0x0C, 0xF0, // t....C..
/* 0AD8 */ 0x39, 0x3A, 0x00, 0x26, 0x55, 0x1C, 0x62, 0x80, // 9:.&U.b.
/* 0AE0 */ 0xF0, 0x60, 0x99, 0xB4, 0xA3, 0x03, 0x4A, 0x12, // .`....J.
/* 0AE8 */ 0x84, 0xA4, 0x1F, 0x62, 0x10, 0x93, 0x8D, 0x7D, // ...b...}
/* 0AF0 */ 0xDE, 0xC7, 0x79, 0x3E, 0xBE, 0xE4, 0x19, 0xFE, // ..y>....
/* 0AF8 */ 0x3D, 0xC1, 0x37, 0x95, 0x20, 0x61, 0x12, 0x14, // =.7. a..
/* 0B00 */ 0x7A, 0x76, 0x40, 0x49, 0xA4, 0xD0, 0xE1, 0xC1, // zv@I....
/* 0B08 */ 0x67, 0x07, 0x2E, 0x09, 0x8E, 0x82, 0xF8, 0xEC, // g.......
/* 0B10 */ 0xE0, 0xB8, 0x67, 0x07, 0xC4, 0xFF, 0xFF, 0xEC, // ..g.....
/* 0B18 */ 0x00, 0x2B, 0xDE, 0x29, 0x06, 0x14, 0xC3, 0x7B, // .+.)...{
/* 0B20 */ 0xEC, 0x00, 0xD7, 0xF8, 0x60, 0x1F, 0x1E, 0x00, // ....`...
/* 0B28 */ 0x27, 0xB1, 0x0E, 0x0F, 0xA0, 0x1B, 0xBA, 0x0F, // '.......
/* 0B30 */ 0x0F, 0xE0, 0x3A, 0x00, 0x00, 0x97, 0xD3, 0x03, // ..:.....
/* 0B38 */ 0x4C, 0x8C, 0xA7, 0x07, 0xD8, 0xFF, 0xFF, 0xD3, // L.......
/* 0B40 */ 0x03, 0xE0, 0x66, 0x7C, 0xB0, 0x4F, 0x0F, 0x80, // ..f|.O..
/* 0B48 */ 0xC3, 0x13, 0x80, 0x4F, 0x0F, 0xC0, 0xEC, 0x00, // ...O....
/* 0B50 */ 0x00, 0x5B, 0xE6, 0xE9, 0x81, 0xFC, 0xFF, 0xC7, // .[......
/* 0B58 */ 0xC0, 0x46, 0xE4, 0x08, 0xA7, 0x07, 0xC4, 0xB4, // .F......
/* 0B60 */ 0x63, 0x44, 0x8D, 0xF9, 0x34, 0x01, 0x5B, 0xEC, // cD..4.[.
/* 0B68 */ 0xF9, 0x01, 0x75, 0xB4, 0xF2, 0x09, 0xDC, 0xE7, // ..u.....
/* 0B70 */ 0x07, 0x2E, 0x0B, 0x8E, 0x82, 0xF8, 0xFC, 0xE0, // ........
/* 0B78 */ 0xC8, 0xE7, 0x07, 0xE8, 0x11, 0xCF, 0x0F, 0xA0, // ........
/* 0B80 */ 0x18, 0xD2, 0xF1, 0x82, 0x6B, 0x84, 0x60, 0x39, // ....k.`9
/* 0B88 */ 0x41, 0x00, 0x4E, 0x0E, 0xF0, 0x3E, 0x41, 0x80, // A.N..>A.
/* 0B90 */ 0xCB, 0xC6, 0x09, 0x02, 0x74, 0x47, 0x00, 0xEC, // ....tG..
/* 0B98 */ 0xFF, 0xFF, 0x08, 0x00, 0x2C, 0xCE, 0x10, 0x60, // ....,..`
/* 0BA0 */ 0x38, 0x53, 0xC0, 0x3E, 0x43, 0x00, 0x96, 0x0E, // 8S.>C...
/* 0BA8 */ 0x35, 0x80, 0xB1, 0x33, 0x04, 0x18, 0xFE, 0xFF, // 5..3....
/* 0BB0 */ 0x67, 0x08, 0xAC, 0x8E, 0x33, 0x04, 0x90, 0x3C, // g...3..<
/* 0BB8 */ 0xD6, 0x80, 0x77, 0xBE, 0xC7, 0x76, 0x00, 0xF6, // ..w..v..
/* 0BC0 */ 0x0C, 0x4D, 0xCE, 0x10, 0x80, 0xB5, 0x11, 0x82, // .M......
/* 0BC8 */ 0xE5, 0x0C, 0x01, 0x4C, 0xFF, 0xFF, 0x67, 0x08, // ...L..g.
/* 0BD0 */ 0x60, 0xE6, 0xE3, 0x0C, 0x01, 0xE4, 0x8E, 0x00, // `.......
/* 0BD8 */ 0x60, 0x91, 0x7C, 0x86, 0x40, 0x49, 0x83, 0x50, // `.|.@I.P
/* 0BE0 */ 0x94, 0x33, 0x04, 0x62, 0xA0, 0xC7, 0x50, 0xFB, // .3.b..P.
/* 0BE8 */ 0x28, 0x04, 0x7A, 0x16, 0x9E, 0x13, 0x1F, 0x02, // (.z.....
/* 0BF0 */ 0x3C, 0xC1, 0xA7, 0x08, 0x94, 0x54, 0x0A, 0x1D, // <....T..
/* 0BF8 */ 0xFF, 0x7C, 0x8A, 0xE0, 0xD2, 0xE0, 0x28, 0x88, // .|....(.
/* 0C00 */ 0x4F, 0x11, 0x8E, 0x7D, 0x8A, 0x80, 0x1E, 0xF3, // O..}....
/* 0C08 */ 0x14, 0x01, 0x0A, 0xB9, 0x63, 0x06, 0xD9, 0x18, // ....c...
/* 0C10 */ 0xC1, 0x76, 0x8E, 0xC0, 0xFE, 0xFF, 0xCF, 0x11, // .v......
/* 0C18 */ 0x80, 0x85, 0xF3, 0xA3, 0xCF, 0x11, 0xE0, 0x1A, // ........
/* 0C20 */ 0x8B, 0xCF, 0x11, 0xE0, 0x3A, 0x04, 0x00, 0xB7, // ....:...
/* 0C28 */ 0xF3, 0x28, 0xCC, 0x01, 0x7B, 0x2A, 0xCF, 0xA3, // .(..{*..
/* 0C30 */ 0x80, 0x9D, 0xFF, 0xFF, 0x88, 0xE1, 0x8D, 0x0F, // ........
/* 0C38 */ 0xF6, 0x79, 0x14, 0x70, 0x68, 0xE4, 0x3C, 0x0A, // .y.ph.<.
/* 0C40 */ 0xE4, 0x0E, 0x00, 0xB0, 0x4F, 0x0F, 0x30, 0x27, // ....O.0'
/* 0C48 */ 0xCA, 0x4E, 0x0F, 0xC0, 0xF4, 0xFF, 0x7F, 0x7A, // .N.....z
/* 0C50 */ 0x00, 0x2E, 0xE3, 0x83, 0x7D, 0x7A, 0x00, 0x1C, // ....}z..
/* 0C58 */ 0x2A, 0x39, 0x3D, 0x00, 0xB9, 0x03, 0x00, 0x6C, // *9=....l
/* 0C60 */ 0x21, 0xA7, 0x07, 0xD4, 0x18, 0x2C, 0xF7, 0xA8, // !....,..
/* 0C68 */ 0xA0, 0x41, 0x9C, 0xC0, 0x41, 0xC4, 0xAC, 0x78, // .A..A..x
/* 0C70 */ 0x40, 0x04, 0xE7, 0x60, 0xE3, 0xD7, 0x78, 0x6E, // @..`..xn
/* 0C78 */ 0xA0, 0x47, 0x07, 0x2E, 0x8E, 0x42, 0xE7, 0x2A, // .G...B.*
/* 0C80 */ 0x1F, 0x1D, 0xB8, 0x18, 0x38, 0x0A, 0xE2, 0x4D, // ....8..M
/* 0C88 */ 0xFC, 0xFF, 0x13, 0x0C, 0x7A, 0x74, 0x80, 0x1E, // ....zt..
/* 0C90 */ 0xEC, 0xE8, 0x00, 0x6D, 0x3A, 0xA7, 0xE7, 0xA1, // ...m:...
/* 0C98 */ 0xB2, 0x43, 0x01, 0x6E, 0xA8, 0x70, 0x07, 0x07, // .C.n.p..
/* 0CA0 */ 0xEF, 0xDC, 0x00, 0x38, 0x09, 0x74, 0x6E, 0x00, // ...8.tn.
/* 0CA8 */ 0xDD, 0x09, 0xC0, 0xE7, 0x06, 0x70, 0x8D, 0x1E, // .....p..
/* 0CB0 */ 0xFC, 0x02, 0xAD, 0xC0, 0xB3, 0xC0, 0x47, 0x04, // ......G.
/* 0CB8 */ 0x05, 0x5B, 0x18, 0x85, 0xB1, 0x87, 0xB3, 0x01, // .[......
/* 0CC0 */ 0x94, 0xD1, 0x1D, 0xDC, 0x31, 0x1D, 0x0E, 0x3B, // ....1..;
/* 0CC8 */ 0xCC, 0x18, 0x8E, 0x0F, 0xFC, 0xFF, 0x7F, 0x20, // .......
/* 0CD0 */ 0x36, 0x3F, 0x14, 0x0D, 0xE4, 0x2C, 0x3D, 0x9F, // 6?...,=.
/* 0CD8 */ 0x90, 0xEC, 0xEC, 0xE7, 0x71, 0x71, 0x29, 0xC7, // ....qq).
/* 0CE0 */ 0x19, 0x9F, 0xB9, 0xC8, 0xA9, 0xCB, 0xF3, 0x7B, // .......{
/* 0CE8 */ 0xAC, 0x30, 0x81, 0x47, 0xC1, 0xD0, 0xF8, 0xD0, // .0.G....
/* 0CF0 */ 0xE1, 0x1D, 0x03, 0x8A, 0x3F, 0x63, 0x90, 0x89, // ....?c..
/* 0CF8 */ 0x1C, 0xE1, 0x1B, 0x86, 0xCF, 0x13, 0x2C, 0xCC, // ......,.
/* 0D00 */ 0x78, 0x41, 0x73, 0x39, 0xA8, 0x19, 0x4B, 0xAF, // xAs9..K.
/* 0D08 */ 0x8D, 0x53, 0xA9, 0x50, 0x80, 0x56, 0x10, 0xCD, // .S.P.V..
/* 0D10 */ 0xE1, 0x0D, 0x21, 0x46, 0x88, 0x78, 0xC7, 0x11, // ..!F.x..
/* 0D18 */ 0x21, 0xA4, 0x71, 0x30, 0x13, 0x8C, 0x73, 0x5E, // !.q0..s^
/* 0D20 */ 0x81, 0x8A, 0x44, 0xA1, 0x73, 0xF7, 0x20, 0x02, // ..D.s. .
/* 0D28 */ 0x1D, 0xD9, 0xE3, 0x00, 0x83, 0x39, 0x86, 0x68, // .....9.h
/* 0D30 */ 0xE7, 0x10, 0x25, 0xD4, 0xF1, 0x31, 0x90, 0x97, // ..%..1..
/* 0D38 */ 0x85, 0x60, 0x1E, 0xA6, 0xC1, 0x4C, 0x10, 0xFA, // .`...L..
/* 0D40 */ 0xB0, 0x30, 0x47, 0x0E, 0x1F, 0x4B, 0xDE, 0x23, // .0G..K.#
/* 0D48 */ 0x7C, 0xA6, 0x60, 0xEE, 0xAF, 0x14, 0x3A, 0x49, // |.`...:I
/* 0D50 */ 0x44, 0x88, 0xF3, 0x28, 0x11, 0xE1, 0xF1, 0x21, // D..(...!
/* 0D58 */ 0x44, 0x5B, 0xE7, 0x90, 0x18, 0xB2, 0x36, 0x77, // D[....6w
/* 0D60 */ 0xA1, 0x84, 0xA8, 0x6D, 0x64, 0x02, 0x8A, 0x12, // ...md...
/* 0D68 */ 0x23, 0x42, 0x6F, 0x10, 0x42, 0x89, 0xD6, 0xDC, // #Bo.B...
/* 0D70 */ 0xBC, 0x84, 0x16, 0x2B, 0x42, 0x90, 0x30, 0x11, // ...+B.0.
/* 0D78 */ 0x63, 0x1F, 0xC0, 0xF3, 0x41, 0xFB, 0x87, 0x4A, // c...A..J
/* 0D80 */ 0xC4, 0xD1, 0x02, 0x37, 0xD6, 0x43, 0x3C, 0xA3, // ...7.C<.
/* 0D88 */ 0x13, 0x3B, 0x3C, 0x13, 0x78, 0x62, 0xE7, 0xF5, // .;<.xb..
/* 0D90 */ 0x78, 0x77, 0x34, 0x0F, 0x00, 0x51, 0x63, 0xC4, // xw4..Qc.
/* 0D98 */ 0x4F, 0xE0, 0xA0, 0xEB, 0xD7, 0x99, 0xC4, 0x91, // O.......
/* 0DA0 */ 0xE0, 0x51, 0x07, 0x0D, 0x1F, 0x16, 0x3C, 0x54, // .Q....<T
/* 0DA8 */ 0x9F, 0x00, 0xDE, 0x4E, 0x0C, 0x72, 0x8E, 0x3E, // ...N.r.>
/* 0DB0 */ 0x75, 0x3C, 0x25, 0x78, 0x0C, 0xEC, 0x90, 0xE4, // u<%x....
/* 0DB8 */ 0x73, 0x81, 0x8F, 0x0D, 0x78, 0xD7, 0x02, 0xFE, // s...x...
/* 0DC0 */ 0xFF, 0x80, 0xEF, 0x0B, 0x4F, 0x0B, 0xEC, 0x1B, // ....O...
/* 0DC8 */ 0x63, 0x38, 0x3E, 0x5E, 0xDF, 0x66, 0x3C, 0x81, // c8>^.f<.
/* 0DD0 */ 0x77, 0x0B, 0x03, 0xB2, 0x23, 0x09, 0xFC, 0xF1, // w...#...
/* 0DD8 */ 0xF8, 0x80, 0xE0, 0xF9, 0x3C, 0x95, 0x26, 0xB0, // ....<.&.
/* 0DE0 */ 0xFC, 0x41, 0xA0, 0x46, 0x66, 0x68, 0x0F, 0xF8, // .A.Ffh..
/* 0DE8 */ 0xB4, 0xDE, 0x13, 0x7C, 0x19, 0x38, 0x2C, 0x26, // ...|.8,&
/* 0DF0 */ 0x16, 0x42, 0x27, 0x1A, 0x8F, 0x07, 0xFC, 0xE7, // .B'.....
/* 0DF8 */ 0x8E, 0xE3, 0x8F, 0x70, 0xFA, 0x9E, 0xAF, 0x0F, // ...p....
/* 0E00 */ 0xA7, 0x3A, 0xB1, 0x80, 0xE2, 0x1C, 0xC1, 0xA0, // .:......
/* 0E08 */ 0x0E, 0x21, 0xFE, 0x41, 0x05, 0x39, 0x84, 0x38, // .!.A.9.8
/* 0E10 */ 0x3E, 0x47, 0xE0, 0x70, 0x8C, 0x72, 0x46, 0x41, // >G.p.rFA
/* 0E18 */ 0x1E, 0x1D, 0xF0, 0x27, 0x89, 0x07, 0x0C, 0xEC, // ...'....
/* 0E20 */ 0x40, 0xF8, 0x69, 0xE0, 0x21, 0x86, 0x01, 0xBF, // @.i.!...
/* 0E28 */ 0xC7, 0x18, 0xFF, 0xB8, 0x7C, 0xF0, 0x30, 0xC2, // ....|.0.
/* 0E30 */ 0xD9, 0x3E, 0x23, 0x3C, 0x7F, 0xF8, 0x44, 0xE1, // .>#<..D.
/* 0E38 */ 0x4B, 0xD2, 0xA9, 0xBD, 0x14, 0x78, 0xE4, 0x7A, // K....x.z
/* 0E40 */ 0xD1, 0x49, 0x03, 0x88, 0xF2, 0x1E, 0xDA, 0xD0, // .I......
/* 0E48 */ 0x7A, 0x80, 0x34, 0x30, 0x76, 0x6D, 0x62, 0x23, // z.40vmb#
/* 0E50 */ 0x63, 0xD7, 0x87, 0xF3, 0xF4, 0xB9, 0x08, 0x97, // c.......
/* 0E58 */ 0xFE, 0x8C, 0x44, 0x4F, 0x00, 0xCE, 0x4D, 0xA2, // ..DO..M.
/* 0E60 */ 0xE4, 0x63, 0xA2, 0x70, 0xCE, 0x7A, 0x16, 0xA1, // .c.p.z..
/* 0E68 */ 0x20, 0x06, 0x74, 0x90, 0xA3, 0x12, 0xFA, 0x98, // .t.....
/* 0E70 */ 0xE2, 0xB3, 0xC8, 0xFF, 0xFF, 0x09, 0xD8, 0x47, // .......G
/* 0E78 */ 0x07, 0x76, 0xF2, 0x60, 0x04, 0x4F, 0x39, 0xCF, // .v.`.O9.
/* 0E80 */ 0x0E, 0x6C, 0x98, 0x3E, 0x15, 0xF0, 0x91, 0xF9, // .l.>....
/* 0E88 */ 0xB0, 0xC4, 0xC0, 0xAB, 0x39, 0xAA, 0xA0, 0xC0, // ....9...
/* 0E90 */ 0x7C, 0x36, 0xC2, 0xE8, 0xBA, 0x19, 0x40, 0x1F, // |6....@.
/* 0E98 */ 0xEE, 0x11, 0x78, 0x28, 0xAF, 0x46, 0x4C, 0xDF, // ..x(.FL.
/* 0EA0 */ 0xD1, 0x08, 0xE4, 0xE8, 0x3C, 0xFC, 0x64, 0x51, // ....<.dQ
/* 0EA8 */ 0x97, 0x3D, 0x4F, 0xD6, 0x20, 0x9E, 0xAC, 0xA3, // .=O. ...
/* 0EB0 */ 0x4C, 0x16, 0x3D, 0x13, 0x5F, 0x23, 0x7C, 0x0A, // L.=._#|.
/* 0EB8 */ 0x63, 0xF7, 0x2B, 0x36, 0xE1, 0xD7, 0x0E, 0x58, // c.+6...X
/* 0EC0 */ 0x37, 0x3E, 0xDC, 0xBD, 0x0A, 0xDE, 0x58, 0x7C, // 7>....X|
/* 0EC8 */ 0xAD, 0x80, 0x3F, 0x5A, 0xEC, 0xF5, 0x0E, 0x58, // ..?Z...X
/* 0ED0 */ 0x5D, 0xA6, 0xC0, 0x73, 0x31, 0x82, 0xF3, 0xFF, // ]..s1...
/* 0ED8 */ 0xBF, 0x62, 0xC1, 0xB9, 0xFE, 0x93, 0xEB, 0x1D, // .b......
/* 0EE0 */ 0xC8, 0x2E, 0x46, 0x98, 0x93, 0x05, 0x03, 0x79, // ..F....y
/* 0EE8 */ 0xB3, 0xC0, 0xDD, 0x33, 0x60, 0x1E, 0x43, 0x7C, // ...3`.C|
/* 0EF0 */ 0xCF, 0x00, 0xD8, 0xF7, 0xFF, 0xBF, 0x67, 0x00, // ......g.
/* 0EF8 */ 0xC6, 0xC7, 0xEF, 0x7B, 0x06, 0x78, 0x0E, 0x16, // ...{.x..
/* 0F00 */ 0xEC, 0x9E, 0x01, 0x3B, 0xF7, 0x3D, 0x03, 0x35, // ...;.=.5
/* 0F08 */ 0x22, 0x6B, 0x3A, 0x1F, 0x41, 0x1A, 0x40, 0x64, // "k:.A.@d
/* 0F10 */ 0xDF, 0x28, 0xD8, 0x65, 0xEC, 0x4D, 0x03, 0x30, // .(.e.M.0
/* 0F18 */ 0xF1, 0xFF, 0xBF, 0x69, 0x00, 0xDC, 0x8B, 0x76, // ...i...v
/* 0F20 */ 0xD3, 0x00, 0x6A, 0x90, 0x1E, 0xCD, 0x9B, 0x06, // ..j.....
/* 0F28 */ 0x18, 0xFE, 0xFF, 0x27, 0x24, 0x38, 0x67, 0x0B, // ...'$8g.
/* 0F30 */ 0xEC, 0x5D, 0x03, 0x3C, 0x67, 0x24, 0xDC, 0x5D, // .].<g$.]
/* 0F38 */ 0x03, 0x60, 0xEA, 0xFF, 0xFF, 0xAE, 0x01, 0x58, // .`.....X
/* 0F40 */ 0x3C, 0xF5, 0xFA, 0xAE, 0x01, 0x6C, 0xCF, 0x49, // <....l.I
/* 0F48 */ 0xB8, 0xD3, 0xAB, 0x87, 0xE7, 0xAB, 0xAA, 0x87, // ........
/* 0F50 */ 0xF8, 0xAE, 0x01, 0xD8, 0xFA, 0xFF, 0xDF, 0x35, // .......5
/* 0F58 */ 0x00, 0xCE, 0x5A, 0xB8, 0x6B, 0x00, 0x95, 0xFF, // ..Z.k...
/* 0F60 */ 0xFF, 0x39, 0x09, 0x8C, 0x77, 0x0D, 0x80, 0xCD, // .9..w...
/* 0F68 */ 0xFF, 0xFF, 0xBB, 0x06, 0x60, 0xE8, 0x96, 0xE0, // ....`...
/* 0F70 */ 0xBB, 0x06, 0x70, 0x52, 0x68, 0xD3, 0xA7, 0x46, // ..pRh..F
/* 0F78 */ 0xA3, 0x56, 0x0D, 0xCA, 0xD4, 0x28, 0xD3, 0xA0, // .V...(..
/* 0F80 */ 0x56, 0x9F, 0x4A, 0x8D, 0x19, 0x9B, 0x40, 0x82, // V.J...@.
/* 0F88 */ 0xB2, 0x9F, 0x50, 0x1A, 0x95, 0xA3, 0x79, 0x00, // ..P...y.
/* 0F90 */ 0x61, 0xC1, 0x56, 0xA3, 0x63, 0x80, 0x23, 0xA9, // a.V.c.#.
/* 0F98 */ 0x00, 0x62, 0x82, 0xD6, 0x29, 0x10, 0x4B, 0xB0, // .b..).K.
/* 0FA0 */ 0x01, 0xD1, 0xC8, 0x15, 0xDB, 0x20, 0x02, 0x72, // ..... .r
/* 0FA8 */ 0x76, 0x20, 0xAA, 0x44, 0x07, 0x10, 0x4B, 0xEB, // v .D..K.
/* 0FB0 */ 0x03, 0x88, 0x65, 0x07, 0x11, 0x90, 0x23, 0xD2, // ..e...#.
/* 0FB8 */ 0x08, 0xC8, 0x79, 0x29, 0x04, 0x64, 0xA5, 0x4A, // ..y).d.J
/* 0FC0 */ 0x80, 0x98, 0x6C, 0x10, 0x01, 0x39, 0x31, 0x10, // ..l..91.
/* 0FC8 */ 0x8D, 0x0F, 0x44, 0x75, 0x3F, 0x1D, 0x04, 0xE4, // ..Du?...
/* 0FD0 */ 0x10, 0x20, 0x02, 0x72, 0x74, 0x20, 0xAA, 0xE3, // . .rt ..
/* 0FD8 */ 0xE7, 0x21, 0x20, 0x67, 0x06, 0x11, 0x90, 0x15, // .! g....
/* 0FE0 */ 0x58, 0x01, 0x62, 0x39, 0xB5, 0x00, 0xB1, 0xD4, // X.b9....
/* 0FE8 */ 0x20, 0x1A, 0x10, 0x59, 0xB9, 0x80, 0x1C, 0x1D, // ..Y....
/* 0FF0 */ 0x44, 0x40, 0x56, 0x6C, 0x06, 0x88, 0xC9, 0x07, // D@Vl....
/* 0FF8 */ 0x11, 0x90, 0x53, 0x03, 0x51, 0x09, 0x6A, 0xFE, // ..S.Q.j.
/* 1000 */ 0xFF, 0x40, 0x4C, 0x39, 0x88, 0x80, 0x1C, 0x03, // .@L9....
/* 1008 */ 0x88, 0xA6, 0x07, 0xA2, 0x52, 0xDC, 0x00, 0xB1, // ....R...
/* 1010 */ 0xD8, 0x20, 0x02, 0xB2, 0x88, 0xF7, 0x84, 0x80, // . ......
/* 1018 */ 0x1C, 0xD9, 0x0E, 0x10, 0xCB, 0x0F, 0x22, 0x20, // ......"
/* 1020 */ 0x67, 0xD5, 0x03, 0xC4, 0x92, 0x83, 0x08, 0xC8, // g.......
/* 1028 */ 0xEA, 0x14, 0x81, 0xB0, 0x6C, 0x20, 0x34, 0xA9, // ....l 4.
/* 1030 */ 0xA3, 0xE1, 0x51, 0x4D, 0x83, 0xA2, 0x9E, 0x40, // ..QM...@
/* 1038 */ 0x98, 0x0E, 0x53, 0xE0, 0x4C, 0x15, 0x88, 0x80, // ..S.L...
/* 1040 */ 0xAC, 0xCF, 0x15, 0x10, 0x53, 0x0B, 0x22, 0x20, // ....S."
/* 1048 */ 0x6B, 0xB6, 0x05, 0xC4, 0x12, 0x80, 0x08, 0xC8, // k.......
/* 1050 */ 0x09, 0x7C, 0x01, 0xB1, 0x3C, 0x20, 0x02, 0x72, // .|..< .r
/* 1058 */ 0x1E, 0x63, 0x40, 0x2C, 0x1D, 0x88, 0x80, 0x9C, // .c@,....
/* 1060 */ 0xEE, 0x99, 0x11, 0x88, 0x64, 0x05, 0x11, 0x90, // ....d...
/* 1068 */ 0xF3, 0x5A, 0x03, 0x62, 0xE9, 0x41, 0x04, 0x64, // .Z.b.A.d
/* 1070 */ 0x0D, 0xE2, 0x80, 0x98, 0x22, 0x10, 0x01, 0x59, // ...."..Y
/* 1078 */ 0x97, 0x3A, 0x20, 0xA6, 0x12, 0x44, 0x40, 0xD6, // .: ..D@.
/* 1080 */ 0x2A, 0x0F, 0x88, 0x29, 0x07, 0x11, 0x90, 0x33, // *..)...3
/* 1088 */ 0xFC, 0x5A, 0x04, 0xE4, 0x44, 0x20, 0x1A, 0x08, // .Z..D ..
/* 1090 */ 0x79, 0x7C, 0x68, 0x20, 0x04, 0x44, 0x40, 0xCE, // y|h .D@.
/* 1098 */ 0xFF, 0x90, 0x08, 0x44, 0xD4, 0x3C, 0x3E, 0x02, // ...D.<>.
/* 10A0 */ 0x11, 0x95, 0x2F, 0x11, 0x01, 0x59, 0x33, 0x88, // ../..Y3.
/* 10A8 */ 0x80, 0x9C, 0xE5, 0x51, 0x11, 0x88, 0x24, 0x03, // ...Q..$.
/* 10B0 */ 0x11, 0x90, 0x93, 0x7F, 0x32, 0x1E, 0x11, 0x98, // ....2...
/* 10B8 */ 0x4A, 0x20, 0xA6, 0xED, 0x49, 0x2D, 0x20, 0x2B, // J ..I- +
/* 10C0 */ 0x05, 0x11, 0x90, 0x55, 0xEB, 0x04, 0x62, 0x19, // ...U..b.
/* 10C8 */ 0x40, 0x34, 0x20, 0xF2, 0x1C, 0x39, 0x20, 0x06, // @4 ..9 .
/* 10D0 */ 0xA2, 0x01, 0x10, 0xA3, 0x87, 0x0A, 0xA6, 0xEA, // ........
/* 10D8 */ 0xD1, 0x21, 0x20, 0x67, 0x02, 0xA1, 0xCA, 0xDE, // .! g....
/* 10E0 */ 0x1A, 0x41, 0x89, 0x4C, 0x10, 0x01, 0x59, 0xD2, // .A.L..Y.
/* 10E8 */ 0x1B, 0x24, 0x10, 0x11, 0x08, 0x22, 0x20, 0x0B, // .$..." .
/* 10F0 */ 0x79, 0xB0, 0x3C, 0x0A, 0x30, 0x10, 0x01, 0x59, // y.<.0..Y
/* 10F8 */ 0x81, 0xDA, 0x03, 0x06, 0x55, 0xFB, 0xFF, 0x3F, // ....U..?
/* 1100 */ 0x60, 0x50, 0xB7, 0x40, 0x4C, 0x88, 0x5C, 0x20, // `P.@L.\
/* 1108 */ 0x16, 0x1A, 0x44, 0x07, 0x07, 0x62, 0xF7, 0xB0, // ..D..b..
/* 1110 */ 0x40, 0xF5, 0x1E, 0x16, 0x28, 0x88, 0x0E, 0x0B, // @...(...
/* 1118 */ 0xE4, 0xD3, 0xF2, 0xB0, 0xC0, 0x40, 0x74, 0x50, // .....@tP
/* 1120 */ 0x20, 0x9F, 0x10, 0x01, 0x39, 0x36, 0x88, 0x0E, // ...96..
/* 1128 */ 0x1B, 0xE4, 0xE9, 0x14, 0x88, 0x04, 0x06, 0x11, // ........
/* 1130 */ 0x90, 0x03, 0x3E, 0x51, 0x04, 0xE4, 0xB4, 0x20, // ..>Q...
/* 1138 */ 0x02, 0x72, 0xB2, 0x47, 0x49, 0x20, 0x92, 0x13, // .r.GI ..
/* 1140 */ 0x44, 0x40, 0xFE, 0xFF, 0x03 // D@...
})
}
}
}

File diff suppressed because it is too large Load Diff

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save