Skip to content

Commit

Permalink
change cfg option name
Browse files Browse the repository at this point in the history
  • Loading branch information
bvr-yr committed Mar 17, 2024
1 parent eae7ce5 commit 664aa92
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions nix/hm-module.nix
Original file line number Diff line number Diff line change
Expand Up @@ -408,7 +408,7 @@ in {
default = false;
};

swap_font = mkOption {
swap_font_color = mkOption {
description = "Whether to swap font color with inner color on some events";
type = bool;
default = false;
Expand Down Expand Up @@ -563,7 +563,7 @@ in {
numlock_color = ${input-field.numlock_color}
bothlock_color = ${input-field.bothlock_color}
invert_numlock = ${boolToString input-field.invert_numlock}
swap_font = ${boolToString input-field.swap_font}
swap_font_color = ${boolToString input-field.swap_font_color}
position = ${toString input-field.position.x}, ${toString input-field.position.y}
halign = ${input-field.halign}
Expand Down
4 changes: 2 additions & 2 deletions src/config/ConfigManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ void CConfigManager::init() {
m_config.addSpecialConfigValue("input-field", "numlock_color", Hyprlang::INT{-1});
m_config.addSpecialConfigValue("input-field", "bothlock_color", Hyprlang::INT{-1});
m_config.addSpecialConfigValue("input-field", "invert_numlock", Hyprlang::INT{0});
m_config.addSpecialConfigValue("input-field", "swap_font", Hyprlang::INT{0});
m_config.addSpecialConfigValue("input-field", "swap_font_color", Hyprlang::INT{0});
SHADOWABLE("input-field");

m_config.addSpecialCategory("label", Hyprlang::SSpecialCategoryOptions{.key = nullptr, .anonymousKeyBased = true});
Expand Down Expand Up @@ -219,7 +219,7 @@ std::vector<CConfigManager::SWidgetConfig> CConfigManager::getWidgetConfigs() {
{"numlock_color", m_config.getSpecialConfigValue("input-field", "numlock_color", k.c_str())},
{"bothlock_color", m_config.getSpecialConfigValue("input-field", "bothlock_color", k.c_str())},
{"invert_numlock", m_config.getSpecialConfigValue("input-field", "invert_numlock", k.c_str())},
{"swap_font", m_config.getSpecialConfigValue("input-field", "swap_font", k.c_str())},
{"swap_font_color", m_config.getSpecialConfigValue("input-field", "swap_font_color", k.c_str())},
SHADOWABLE("input-field"),
}
});
Expand Down
2 changes: 1 addition & 1 deletion src/renderer/widgets/PasswordInputField.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ CPasswordInputField::CPasswordInputField(const Vector2D& viewport_, const std::u
col.caps = std::any_cast<Hyprlang::INT>(props.at("capslock_color"));
col.num = std::any_cast<Hyprlang::INT>(props.at("numlock_color"));
col.invertNum = std::any_cast<Hyprlang::INT>(props.at("invert_numlock"));
col.swapFont = std::any_cast<Hyprlang::INT>(props.at("swap_font"));
col.swapFont = std::any_cast<Hyprlang::INT>(props.at("swap_font_color"));
viewport = viewport_;

auto POS__ = std::any_cast<Hyprlang::VEC2>(props.at("position"));
Expand Down

0 comments on commit 664aa92

Please sign in to comment.