128 sidebar =
new Gtk.Box(Gtk.Orientation.VERTICAL, 12);
129 sidebar.set_size_request(230, -1);
130 sidebar.hexpand =
false;
131 sidebar.vexpand =
true;
132 sidebar.halign = Gtk.Align.FILL;
133 sidebar.valign = Gtk.Align.FILL;
134 sidebar.get_style_context().add_class(
"sidebar");
136 var sidebar_header =
new Gtk.Box(Gtk.Orientation.HORIZONTAL, 8);
137 sidebar_header.margin_start = 12;
138 sidebar_header.margin_end = 12;
139 sidebar_header.margin_top = 12;
140 sidebar_header.margin_bottom = 12;
141 sidebar_header.get_style_context().add_class(
"sidebar-header");
143 Gtk.Widget logo_widget;
145 logo_widget =
new Gtk.Image.from_pixbuf(
IconManager.
lookup(
"bastionguard-backup", 48));
148 logo_widget =
themed_icon(
"preferences-system-symbolic", 48);
151 var title =
new Gtk.Label(
"BastionGuard™\nSettings");
155 title.max_width_chars = 14;
156 title.get_style_context().add_class(
"sidebar-title");
158 sidebar_header.append(logo_widget);
159 sidebar_header.append(title);
169 sidebar.append(sidebar_header);
177 var spacer =
new Gtk.Box(Gtk.Orientation.VERTICAL, 0);
178 spacer.hexpand =
true;
179 spacer.vexpand =
true;
180 spacer.halign = Gtk.Align.FILL;
181 spacer.valign = Gtk.Align.FILL;
184 btn_close.margin_bottom = 12;
185 btn_close.margin_start = 8;
186 btn_close.margin_end = 8;
192 content_box =
new Gtk.Box(Gtk.Orientation.VERTICAL, 0);
193 content_box.hexpand =
true;
194 content_box.vexpand =
true;
195 content_box.halign = Gtk.Align.FILL;
196 content_box.valign = Gtk.Align.FILL;
197 content_box.get_style_context().add_class(
"content");
200 content_header_box.margin_start = 20;
201 content_header_box.margin_end = 20;
202 content_header_box.margin_top = 20;
203 content_header_box.margin_bottom = 20;
204 content_header_box.margin_bottom = 8;
207 lbl_page_title.xalign = 0.0f;
213 content_body_box.hexpand =
true;
214 content_body_box.vexpand =
true;
215 content_body_box.halign = Gtk.Align.FILL;
216 content_body_box.valign = Gtk.Align.FILL;
217 content_body_box.margin_start = 20;
218 content_body_box.margin_end = 20;
219 content_body_box.margin_bottom = 12;
221 stack =
new Gtk.Stack();
222 stack.hexpand =
true;
223 stack.vexpand =
true;
224 stack.halign = Gtk.Align.FILL;
225 stack.valign = Gtk.Align.FILL;
226 stack.set_transition_duration(120);
227 stack.set_transition_type(Gtk.StackTransitionType.SLIDE_UP_DOWN);
231 bottom_bar =
new Gtk.Box(Gtk.Orientation.HORIZONTAL, 8);
232 bottom_bar.margin_start = 20;
233 bottom_bar.margin_end = 20;
234 bottom_bar.margin_bottom = 20;
235 bottom_bar.halign = Gtk.Align.END;
237 var btn_cancel =
new Gtk.Button.with_label(
_(
"Cancel"));
238 btn_cancel.set_size_request(110, -1);
239 btn_cancel.get_style_context().add_class(
"btn-cancel");
241 btn_prev =
new Gtk.Button.with_label(
_(
"Previous"));
243 btn_prev.get_style_context().add_class(
"btn-back");
245 btn_next =
new Gtk.Button.with_label(
_(
"Next"));
247 btn_next.get_style_context().add_class(
"btn-next");
249 var btn_ok =
new Gtk.Button.with_label(
_(
"OK"));
250 btn_ok.set_size_request(110, -1);
251 btn_ok.get_style_context().add_class(
"btn-finish");
252 btn_ok.get_style_context().add_class(
"suggested-action");
259 btn_cancel.clicked.connect(() => {
272 btn_ok.clicked.connect(() => {