diff options
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/Button.cpp | 2 | ||||
-rw-r--r-- | src/gui/ComboBox.cpp | 2 | ||||
-rw-r--r-- | src/gui/SettingsPage.cpp | 10 |
3 files changed, 8 insertions, 6 deletions
diff --git a/src/gui/Button.cpp b/src/gui/Button.cpp index d8cb85b..6e343c4 100644 --- a/src/gui/Button.cpp +++ b/src/gui/Button.cpp @@ -63,7 +63,7 @@ namespace gsr { window.draw(sprite); const int padding_icon_right = padding_right_icon_scale * get_button_height(); - text.set_position((sprite.get_position() + mgl::vec2f(sprite.get_size().x + padding_icon_right, sprite.get_size().y * 0.5f - text.get_bounds().size.y * 0.5f)).floor()); + text.set_position((sprite.get_position() + mgl::vec2f(sprite.get_size().x + padding_icon_right, sprite.get_size().y * 0.5f - text.get_bounds().size.y * 0.52f)).floor()); window.draw(text); } else { text.set_position((draw_pos + item_size * 0.5f - text.get_bounds().size * 0.5f).floor()); diff --git a/src/gui/ComboBox.cpp b/src/gui/ComboBox.cpp index 08c4ec2..dbe9aa0 100644 --- a/src/gui/ComboBox.cpp +++ b/src/gui/ComboBox.cpp @@ -85,7 +85,7 @@ namespace gsr { void ComboBox::add_item(const std::string &text, const std::string &id) { items.push_back({mgl::Text(text, *font), id, {0.0f, 0.0f}}); - items.back().text.set_max_width(font->get_character_size() * 25); // TODO: Make a proper solution + items.back().text.set_max_width(font->get_character_size() * 22); // TODO: Make a proper solution //items.back().text.set_max_rows(1); dirty = true; } diff --git a/src/gui/SettingsPage.cpp b/src/gui/SettingsPage.cpp index 94eeb0d..af338c8 100644 --- a/src/gui/SettingsPage.cpp +++ b/src/gui/SettingsPage.cpp @@ -227,8 +227,9 @@ namespace gsr { } std::unique_ptr<Button> SettingsPage::create_remove_audio_device_button(List *audio_input_list_ptr, List *audio_device_list_ptr) { - auto remove_audio_track_button = std::make_unique<Button>(&get_theme().body_font, "", mgl::vec2f(0.0f, 0.0f), mgl::Color(35, 40, 44)); - remove_audio_track_button->set_icon(&get_theme().trash_texture); + auto remove_audio_track_button = std::make_unique<Button>(&get_theme().body_font, "Delete", mgl::vec2f(0.0f, 0.0f), mgl::Color(0, 0, 0, 120)); + remove_audio_track_button->set_icon(&get_theme().delete_texture); + remove_audio_track_button->set_icon_padding_scale(1.0f); remove_audio_track_button->on_click = [audio_input_list_ptr, audio_device_list_ptr]() { audio_input_list_ptr->remove_widget(audio_device_list_ptr); }; @@ -349,8 +350,9 @@ namespace gsr { auto list = std::make_unique<List>(List::Orientation::HORIZONTAL, List::Alignment::CENTER); list->add_widget(std::make_unique<Label>(&get_theme().title_font, title, get_color_theme().text_color)); - auto remove_track_button = std::make_unique<Button>(&get_theme().body_font, "", mgl::vec2f(0.0f, 0.0f), mgl::Color(35, 40, 44)); - remove_track_button->set_icon(&get_theme().trash_texture); + auto remove_track_button = std::make_unique<Button>(&get_theme().body_font, "Delete", mgl::vec2f(0.0f, 0.0f), mgl::Color(0, 0, 0, 120)); + remove_track_button->set_icon(&get_theme().delete_texture); + remove_track_button->set_icon_padding_scale(1.0f); remove_track_button->on_click = [this, audio_track_subsection]() { audio_track_section_list_ptr->remove_widget(audio_track_subsection); update_audio_track_titles(audio_track_section_list_ptr); |