1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-29 11:47:36 +00:00

MouseSettings: Add tab to configure cursor highlighting

This adds a nice little tab, including a preview, for configuring
the cursor highlighting. Which allows setting the color, size/radius,
and opacity.
This commit is contained in:
MacDue 2022-06-04 20:41:13 +01:00 committed by Linus Groh
parent 5fc13e1d53
commit b558d899ea
7 changed files with 295 additions and 1 deletions

View file

@ -0,0 +1,99 @@
@GUI::Frame {
fill_with_background_color: true
layout: @GUI::VerticalBoxLayout {
margins: [10]
}
@GUI::Frame {
layout: @GUI::HorizontalBoxLayout {}
name: "preview_frame"
fixed_width: 136
fixed_height: 136
}
@GUI::GroupBox {
title: "Highlight color"
fixed_height: 80
layout: @GUI::VerticalBoxLayout {
margins: [6]
spacing: 2
}
@GUI::Widget {}
@GUI::ColorInput {
name: "highlight_color_input"
has_alpha_channel: false
}
@GUI::Widget {}
}
@GUI::GroupBox {
title: "Highlight opacity"
fixed_height: 80
layout: @GUI::VerticalBoxLayout {
margins: [6]
spacing: 2
}
@GUI::Widget {
layout: @GUI::HorizontalBoxLayout {
margins: [8]
spacing: 8
}
@GUI::Label {
autosize: true
text: "0%"
}
@GUI::Slider {
name: "highlight_opacity_slider"
orientation: "Horizontal"
max: 230
min: 0
value: 80
}
@GUI::Label {
autosize: true
text: "100%"
}
}
}
@GUI::GroupBox {
title: "Highlight size"
fixed_height: 80
layout: @GUI::VerticalBoxLayout {
margins: [6]
spacing: 2
}
@GUI::Widget {
layout: @GUI::HorizontalBoxLayout {
margins: [8]
spacing: 8
}
@GUI::Label {
autosize: true
text: "Off"
}
@GUI::Slider {
name: "highlight_radius_slider"
orientation: "Horizontal"
max: 60
min: 19
value: 30
}
@GUI::Label {
autosize: true
text: "Largest"
}
}
}
}