pub struct Resolution {
pub dll_overrides: Vec<DllOverride>,
pub dll_overrides_from: Vec<Origin>,
pub dll_overrides_reset: Vec<DllOverrideReset>,
pub arguments: Vec<Argument>,
pub arguments_from: Vec<Origin>,
pub arguments_dropped: Vec<ArgumentsDropped>,
pub debug_channels: Vec<DebugChannel>,
pub debug_channels_from: Vec<Origin>,
pub env: Vec<EnvEntry>,
pub env_from: Vec<EnvFrom>,
/* private fields */
}Expand description
The settings that apply to one process.
Every matching rule folded in the order Table::resolve describes, so a
scalar holds the value of the last rule that set it and the lists
accumulate. Also says where each value came from, for the log.
Fields§
§dll_overrides: Vec<DllOverride>The dll_overrides entries of every matching rule in fold order,
without the default entries, which only take modules out of the
entries before them.
dll_overrides_from: Vec<Origin>Where each entry of Resolution::dll_overrides came from, at the
same index.
dll_overrides_reset: Vec<DllOverrideReset>Each module a <module>=default entry named, in fold order, with
what that did to the entries before it.
arguments: Vec<Argument>The texts to append to the command line, in fold order, after any
arguments_override replaced what came before it.
arguments_from: Vec<Origin>Where each entry of Resolution::arguments came from, at the same
index.
arguments_dropped: Vec<ArgumentsDropped>Each arguments_override that dropped entries from the argument
list, in fold order.
debug_channels: Vec<DebugChannel>The debug_channels entries of every matching rule in fold order,
which compatdb.so only logs (see Rule::debug_channels).
debug_channels_from: Vec<Origin>Where each entry of Resolution::debug_channels came from, at the
same index.
env: Vec<EnvEntry>The env entries of every matching rule in fold order, followed by
those Resolution::fold_derived_env adds.
Resolution::env_steps says which of them apply in a process.
env_from: Vec<EnvFrom>Where each entry of Resolution::env came from, at the same index.
Implementations§
Source§impl Resolution
impl Resolution
Sourcepub fn is_empty(&self) -> bool
pub fn is_empty(&self) -> bool
Whether there is nothing to apply or log: no value of a scalar setting and no entry of a list.
Sourcepub fn scalar(&self, scalar: Scalar) -> &ScalarState
pub fn scalar(&self, scalar: Scalar) -> &ScalarState
Where the scalar setting scalar ended up: its value and the rule
that set it, or the rule that reset it.
Sourcepub fn dxgi(&self) -> Option<Dxgi>
pub fn dxgi(&self) -> Option<Dxgi>
The DXGI-family implementation (see Rule::dxgi), None when no
rule sets it.
Sourcepub fn d3d9(&self) -> Option<D3d9>
pub fn d3d9(&self) -> Option<D3d9>
The D3D9 implementation (see Rule::d3d9), None when no rule
sets it.
Sourcepub fn wined3d(&self) -> Option<Wined3d>
pub fn wined3d(&self) -> Option<Wined3d>
The renderer of wined3d (see Rule::wined3d), None when no rule
sets it.
Sourcepub fn opengl(&self) -> Option<OpenGl>
pub fn opengl(&self) -> Option<OpenGl>
Which OpenGL the Mac driver gives (see Rule::opengl), None when
no rule sets it.
Sourcepub fn dpi_aware(&self) -> Option<bool>
pub fn dpi_aware(&self) -> Option<bool>
The DPI awareness (see Rule::dpi_aware), None when no rule sets
it.
Sourcepub fn large_address_aware(&self) -> Option<bool>
pub fn large_address_aware(&self) -> Option<bool>
Whether large address awareness is forced (see
Rule::large_address_aware), None when no rule sets it.
Sourcepub fn gcmouse(&self) -> Option<bool>
pub fn gcmouse(&self) -> Option<bool>
Whether mouse movement comes from GCMouse (see Rule::gcmouse),
None when no rule sets it.
Sourcepub fn force_nx(&self) -> Option<bool>
pub fn force_nx(&self) -> Option<bool>
Whether no-execute stays on (see Rule::force_nx), None when no
rule sets it.
Sourcepub fn metal_hud(&self) -> Option<bool>
pub fn metal_hud(&self) -> Option<bool>
Whether the Metal performance HUD shows (see Rule::metal_hud),
None when no rule sets it.
Sourcepub fn d3d_config(&self) -> Option<&str>
pub fn d3d_config(&self) -> Option<&str>
The value the rules’ own env entries leave WINE_D3D_CONFIG at:
the last entry for it, Some("") when that one removes it, and None
when no rule sets it.
Sourcepub fn fold_derived_env(&mut self)
pub fn fold_derived_env(&mut self)
Fold the settings that compatdb.so applies as environment entries
into Resolution::env, each with the rule that set the setting as
its origin and none of them a default:
Resolution::wined3d, when a rule sets it: theWINE_D3D_CONFIGthat names the renderer, after the rules’ own entries. It is the value the variable ends up with, and it keeps the other options a rule’sWINE_D3D_CONFIGset (seeruntime::wined3d_config). Unset, the process keeps whateverWINE_D3D_CONFIGit has, from a rule’senvor inherited, and without one wined3d uses OpenGL.Resolution::metal_hud, when a rule sets it: the entries ofmetal_hud_env, which set or remove theMTL_HUD_variables. They go where the rule that set it folded, before that rule’s ownenventries, so anenventry for one of the variables from that rule or from any rule folded after it wins. Unset, the process keeps the ones it was started with.
Call it after Table::resolve, which records where each setting
came from; a setting without that record adds nothing. A second call
changes nothing.
Sourcepub fn d3d_config_origin(&self) -> Option<&Origin>
pub fn d3d_config_origin(&self) -> Option<&Origin>
Where the env entry that leaves WINE_D3D_CONFIG at
Resolution::d3d_config came from, or None when no rule sets it.
Sourcepub fn env_steps(&self, has: impl Fn(&str) -> bool) -> Vec<EnvStep>
pub fn env_steps(&self, has: impl Fn(&str) -> bool) -> Vec<EnvStep>
The env entries in order, each with the rule that set it and whether
it applies in a process where has says which variables the process
already has. A default leaves such a variable alone, so a value the
caller exported wins over a built-in * rule; every other entry
applies, replacing the value or, when empty, removing the variable.
An entry that a later applied entry for the same variable replaces
says where that entry came from.
Resolution::env_from has one entry per env entry, as
Table::resolve and Resolution::fold_derived_env keep it.
Trait Implementations§
Source§impl Clone for Resolution
impl Clone for Resolution
Source§fn clone(&self) -> Resolution
fn clone(&self) -> Resolution
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more