checkbox: Correctly align label

The label needs to be center-aligned vertically so it's positioned in
the middle of the surrounding box, not at the top.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/967
This commit is contained in:
Jonas Dreßler 2020-01-30 15:26:32 +01:00
parent 0b3fec22d7
commit 0f4aeb2654

View File

@ -19,7 +19,7 @@ class CheckBox extends St.Button {
this._box = new St.Bin({ y_align: Clutter.ActorAlign.START });
container.add_actor(this._box);
this._label = new St.Label();
this._label = new St.Label({ y_align: Clutter.ActorAlign.CENTER });
this._label.clutter_text.set_line_wrap(true);
this._label.clutter_text.set_ellipsize(Pango.EllipsizeMode.NONE);
container.add_actor(this._label);