Skip to content

Commit

Permalink
Add add_mark function to He.Slider
Browse files Browse the repository at this point in the history
  • Loading branch information
lainsce committed Jan 30, 2024
1 parent 46605fe commit 65277a8
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions lib/Widgets/Slider.vala
Original file line number Diff line number Diff line change
Expand Up @@ -129,4 +129,11 @@ public class He.Slider : He.Bin, Gtk.Buildable {
main_box.add_css_class ("slider");
main_box.set_parent (this);
}

/**
* Adds a mark with some information along the trough of the Slider.
*/
public void add_mark (double value, string? text) {
scale.add_mark (value, Gtk.PositionType.BOTTOM, text);
}
}

0 comments on commit 65277a8

Please sign in to comment.