cc-night-light-dialog.ui 30.4 KB
Newer Older
1 2
<?xml version="1.0" encoding="UTF-8"?>
<interface>
3
  <template class="CcNightLightDialog" parent="GtkDialog">
4 5 6 7
    <property name="can_focus">False</property>
    <property name="resizable">False</property>
    <property name="modal">True</property>
    <property name="type_hint">dialog</property>
8
    <signal name="delete-event" handler="gtk_widget_hide_on_delete" object="CcNightLightDialog" swapped="no" />
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50
    <child internal-child="vbox">
      <object class="GtkBox">
        <property name="can_focus">False</property>
        <property name="orientation">vertical</property>
        <property name="spacing">2</property>
        <child internal-child="action_area">
          <object class="GtkButtonBox">
            <property name="can_focus">False</property>
            <property name="layout_style">end</property>
          </object>
          <packing>
            <property name="expand">False</property>
            <property name="fill">False</property>
            <property name="position">0</property>
          </packing>
        </child>
        <child>
          <object class="GtkBox">
            <property name="visible">True</property>
            <property name="can_focus">False</property>
            <property name="orientation">vertical</property>
            <child>
              <object class="GtkInfoBar" id="infobar_disabled">
                <property name="name">infobar_disabled</property>
                <property name="visible">True</property>
                <property name="can_focus">False</property>
                <property name="border_width">0</property>
                <property name="orientation">vertical</property>
                <property name="spacing">12</property>
                <child internal-child="action_area">
                  <object class="GtkButtonBox">
                    <property name="can_focus">False</property>
                    <property name="border_width">12</property>
                    <property name="spacing">6</property>
                    <property name="layout_style">end</property>
                    <child>
                      <object class="GtkButton" id="button_undisable">
                        <property name="label" translatable="yes" comments="This cancels the redshift inhibit.">Restart Filter</property>
                        <property name="name">button_undisable</property>
                        <property name="visible">True</property>
                        <property name="can_focus">True</property>
                        <property name="receives_default">True</property>
51
                        <signal name="clicked" handler="dialog_undisable_clicked_cb" object="CcNightLightDialog" swapped="no" />
52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78
                      </object>
                      <packing>
                        <property name="expand">False</property>
                        <property name="fill">False</property>
                        <property name="pack_type">end</property>
                        <property name="position">0</property>
                      </packing>
                    </child>
                  </object>
                  <packing>
                    <property name="expand">False</property>
                    <property name="fill">False</property>
                    <property name="pack_type">end</property>
                    <property name="position">0</property>
                  </packing>
                </child>
                <child internal-child="content_area">
                  <object class="GtkBox">
                    <property name="can_focus">False</property>
                    <property name="spacing">16</property>
                    <child>
                      <object class="GtkLabel">
                        <property name="visible">True</property>
                        <property name="can_focus">False</property>
                        <property name="halign">start</property>
                        <property name="margin_left">12</property>
                        <property name="hexpand">False</property>
79
                        <property name="label" translatable="yes" comments="Inhibit the redshift functionality until the next day starts">Temporarily Disabled Until Tomorrow</property>
80 81 82 83 84 85 86 87 88
                        <attributes>
                          <attribute name="weight" value="bold"/>
                        </attributes>
                      </object>
                    </child>
                  </object>
                </child>
              </object>
            </child>
89

90
            <child>
91
              <object class="GtkBox">
92 93
                <property name="visible">True</property>
                <property name="can_focus">False</property>
94
                <property name="margin_top">30</property>
95 96
                <property name="margin_end">36</property>
                <property name="margin_start">36</property>
97
                <property name="margin_bottom">36</property>
98
                <property name="orientation">vertical</property>
99
                <property name="spacing">26</property>
100
                <child>
101 102 103 104 105 106 107 108 109 110 111 112 113 114 115
                  <object class="GtkLabel">
                    <property name="visible">True</property>
                    <property name="can_focus">False</property>
                    <property name="halign">start</property>
                    <property name="valign">start</property>
                    <property name="label" translatable="yes">Night light makes the screen color warmer. This can help to prevent eye strain and sleeplessness.</property>
                    <property name="wrap">True</property>
                    <property name="max_width_chars">60</property>
                    <property name="xalign">0</property>
                    <style>
                      <class name="dim-label"/>
                    </style>
                  </object>
                </child>
                <child>
116
                  <object class="GtkFrame">
117 118
                    <property name="visible">True</property>
                    <property name="can_focus">False</property>
119 120
                    <property name="shadow_type">none</property>
                    <child type="label">
121
                      <object class="GtkLabel">
122
                        <property name="visible">True</property>
123 124 125
                        <property name="can_focus">False</property>
                        <property name="halign">start</property>
                        <property name="hexpand">True</property>
126
                        <property name="margin-bottom">22</property>
127 128 129 130
                        <property name="label" translatable="yes">Schedule</property>
                        <attributes>
                          <attribute name="weight" value="bold"/>
                        </attributes>
131 132 133
                      </object>
                    </child>
                    <child>
134
                      <object class="GtkBox">
135
                        <property name="visible">True</property>
136
                        <property name="can_focus">False</property>
137 138
                        <property name="orientation">vertical</property>
                        <property name="spacing">22</property>
139
                        <child>
140
                          <object class="GtkButtonBox" id="togglebutton_box">
141
                            <property name="visible">True</property>
142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197
                            <property name="can_focus">False</property>
                            <property name="halign">fill</property>
                            <property name="hexpand">True</property>
                            <property name="layout_style">expand</property>
                            <child>
                              <object class="GtkRadioButton" id="togglebutton_automatic">
                                <property name="label" translatable="yes">Sunset to Sunrise</property>
                                <property name="visible">True</property>
                                <property name="can_focus">True</property>
                                <property name="receives_default">True</property>
                                <property name="draw_indicator">False</property>
                                <property name="active">True</property>
                                <signal name="toggled" handler="dialog_mode_changed_cb" object="CcNightLightDialog" swapped="no" />
                              </object>
                              <packing>
                                <property name="expand">True</property>
                                <property name="fill">True</property>
                                <property name="position">0</property>
                              </packing>
                            </child>
                            <child>
                              <object class="GtkRadioButton" id="togglebutton_manual">
                                <property name="label" translatable="yes">Manual</property>
                                <property name="visible">True</property>
                                <property name="can_focus">True</property>
                                <property name="receives_default">True</property>
                                <property name="group">togglebutton_automatic</property>
                                <property name="draw_indicator">False</property>
                                <signal name="toggled" handler="dialog_mode_changed_cb" object="CcNightLightDialog" swapped="no" />
                              </object>
                              <packing>
                                <property name="expand">True</property>
                                <property name="fill">True</property>
                                <property name="position">1</property>
                              </packing>
                            </child>
                            <child>
                              <object class="GtkRadioButton" id="togglebutton_off">
                                <property name="label" translatable="yes">_Off</property>
                                <property name="visible">True</property>
                                <property name="can_focus">True</property>
                                <property name="receives_default">True</property>
                                <property name="draw_indicator">False</property>
                                <property name="group">togglebutton_automatic</property>
                                <property name="use_underline">True</property>
                                <signal name="toggled" handler="dialog_mode_changed_cb" object="CcNightLightDialog" swapped="no" />
                              </object>
                              <packing>
                                <property name="expand">True</property>
                                <property name="fill">True</property>
                                <property name="position">2</property>
                              </packing>
                            </child>
                            <style>
                              <class name="linked"/>
                            </style>
198 199
                          </object>
                        </child>
200 201 202 203 204 205 206 207
                      </object>
                    </child>
                  </object>
                </child>
                <child>
                  <object class="GtkBox" id="box_manual">
                    <property name="visible">True</property>
                    <property name="can_focus">False</property>
208 209 210 211 212 213 214
                    <property name="margin-top">12</property>
                    <property name="spacing">18</property>
                    <child>
                      <object class="GtkLabel">
                        <property name="visible">True</property>
                        <property name="can_focus">False</property>
                        <property name="halign">start</property>
215
                        <property name="valign">center</property>
216
                        <property name="label" translatable="yes">From</property>
217
                        <property name="mnemonic_widget">spinbutton_from_hours</property>
218 219 220 221 222
                        <style>
                          <class name="dim-label"/>
                        </style>
                      </object>
                    </child>
223 224 225 226
                    <child>
                      <object class="GtkBox">
                        <property name="visible">True</property>
                        <property name="can_focus">False</property>
227 228 229 230 231 232 233 234 235 236 237 238
                        <property name="spacing">6</property>
                        <child>
                          <object class="GtkSpinButton" id="spinbutton_from_hours">
                            <property name="visible">True</property>
                            <property name="can_focus">True</property>
                            <property name="max_width_chars">2</property>
                            <property name="text">4</property>
                            <property name="orientation">vertical</property>
                            <property name="adjustment">adjustment_from_hours</property>
                            <property name="numeric">True</property>
                            <property name="wrap">True</property>
                            <property name="value">4</property>
239
                            <signal name="output" handler="dialog_format_hours_combobox" object="CcNightLightDialog" swapped="no" />
240 241 242
                            <style>
                              <class name="padded-spinbutton"/>
                            </style>
243 244 245 246 247
                            <child internal-child="accessible">
                              <object class="AtkObject" id="from_h_spinbutton-atkobject">
                                <property name="AtkObject::accessible-description" translatable="yes">Hour</property>
                              </object>
                            </child>
248 249
                          </object>
                        </child>
250 251 252 253
                        <child>
                          <object class="GtkLabel">
                            <property name="visible">True</property>
                            <property name="can_focus">False</property>
254 255 256 257 258 259 260 261 262 263 264 265 266
                            <property name="label" translatable="yes">:</property>
                          </object>
                        </child>
                        <child>
                          <object class="GtkSpinButton" id="spinbutton_from_minutes">
                            <property name="visible">True</property>
                            <property name="can_focus">True</property>
                            <property name="max_width_chars">2</property>
                            <property name="text">0</property>
                            <property name="orientation">vertical</property>
                            <property name="adjustment">adjustment_from_minutes</property>
                            <property name="numeric">True</property>
                            <property name="wrap">True</property>
267
                            <signal name="output" handler="dialog_format_minutes_combobox" object="CcNightLightDialog" swapped="no" />
268
                            <style>
269
                              <class name="padded-spinbutton"/>
270
                            </style>
271 272 273 274 275
                            <child internal-child="accessible">
                              <object class="AtkObject" id="from_m_spinbutton-atkobject">
                                <property name="AtkObject::accessible-description" translatable="yes">Minute</property>
                              </object>
                            </child>
276 277 278
                          </object>
                        </child>
                        <child>
279
                          <object class="GtkStack" id="stack_from">
280 281 282
                            <property name="visible">True</property>
                            <property name="can_focus">False</property>
                            <child>
283 284
                              <object class="GtkButton" id="button_from_am">
                                <property name="label" translatable="yes" comments="This is the short form for the time period in the morning">AM</property>
285 286
                                <property name="visible">True</property>
                                <property name="can_focus">True</property>
287 288
                                <property name="receives_default">True</property>
                                <property name="valign">center</property>
289
                                <signal name="clicked" handler="dialog_am_pm_from_button_clicked_cb" object="CcNightLightDialog" swapped="no" />
290
                                <style>
291
                                  <class name="unpadded-button"/>
292 293 294
                                </style>
                              </object>
                              <packing>
295
                                <property name="name">am</property>
296 297 298
                              </packing>
                            </child>
                            <child>
299 300
                              <object class="GtkButton" id="button_from_pm">
                                <property name="label" translatable="yes" comments="This is the short form for the time period in the afternoon">PM</property>
301 302
                                <property name="visible">True</property>
                                <property name="can_focus">True</property>
303 304
                                <property name="receives_default">True</property>
                                <property name="valign">center</property>
305
                                <signal name="clicked" handler="dialog_am_pm_from_button_clicked_cb" object="CcNightLightDialog" swapped="no" />
306
                                <style>
307
                                  <class name="unpadded-button"/>
308 309 310
                                </style>
                              </object>
                              <packing>
311 312
                                <property name="name">pm</property>
                                <property name="position">1</property>
313 314 315
                              </packing>
                            </child>
                            <child>
316
                              <object class="GtkLabel">
317 318 319 320
                                <property name="visible">True</property>
                                <property name="can_focus">False</property>
                              </object>
                              <packing>
321 322
                                <property name="name">blank</property>
                                <property name="position">2</property>
323 324 325 326 327 328 329 330 331 332
                              </packing>
                            </child>
                          </object>
                        </child>
                      </object>
                    </child>
                    <child>
                      <object class="GtkBox">
                        <property name="visible">True</property>
                        <property name="can_focus">False</property>
333 334 335 336 337 338 339 340 341 342 343 344 345
                        <property name="spacing">6</property>
                        <child>
                          <object class="GtkSpinButton" id="spinbutton_to_hours">
                            <property name="visible">True</property>
                            <property name="can_focus">True</property>
                            <property name="max_width_chars">2</property>
                            <property name="text">4</property>
                            <property name="input_purpose">number</property>
                            <property name="orientation">vertical</property>
                            <property name="adjustment">adjustment_to_hours</property>
                            <property name="numeric">True</property>
                            <property name="wrap">True</property>
                            <property name="value">4</property>
346
                            <signal name="output" handler="dialog_format_hours_combobox" object="CcNightLightDialog" swapped="no" />
347 348 349
                            <style>
                              <class name="padded-spinbutton"/>
                            </style>
350 351 352 353 354
                            <child internal-child="accessible">
                              <object class="AtkObject" id="to_h_spinbutton-atkobject">
                                <property name="AtkObject::accessible-description" translatable="yes">Hour</property>
                              </object>
                            </child>
355 356
                          </object>
                        </child>
357 358 359 360
                        <child>
                          <object class="GtkLabel">
                            <property name="visible">True</property>
                            <property name="can_focus">False</property>
361 362 363 364 365 366 367 368 369 370 371 372 373
                            <property name="label" translatable="yes">:</property>
                          </object>
                        </child>
                        <child>
                          <object class="GtkSpinButton" id="spinbutton_to_minutes">
                            <property name="visible">True</property>
                            <property name="can_focus">True</property>
                            <property name="max_width_chars">2</property>
                            <property name="text">0</property>
                            <property name="orientation">vertical</property>
                            <property name="adjustment">adjustment_to_minutes</property>
                            <property name="numeric">True</property>
                            <property name="wrap">True</property>
374
                            <signal name="output" handler="dialog_format_minutes_combobox" object="CcNightLightDialog" swapped="no" />
375
                            <style>
376
                              <class name="padded-spinbutton"/>
377
                            </style>
378 379 380 381 382
                            <child internal-child="accessible">
                              <object class="AtkObject" id="to_m_spinbutton-atkobject">
                                <property name="AtkObject::accessible-description" translatable="yes">Minute</property>
                              </object>
                            </child>
383 384 385
                          </object>
                        </child>
                        <child>
386
                          <object class="GtkStack" id="stack_to">
387 388 389
                            <property name="visible">True</property>
                            <property name="can_focus">False</property>
                            <child>
390 391
                              <object class="GtkButton" id="button_to_am">
                                <property name="label" translatable="yes">AM</property>
392 393
                                <property name="visible">True</property>
                                <property name="can_focus">True</property>
394 395
                                <property name="receives_default">True</property>
                                <property name="valign">center</property>
396
                                <signal name="clicked" handler="dialog_am_pm_to_button_clicked_cb" object="CcNightLightDialog" swapped="no" />
397
                                <style>
398
                                  <class name="unpadded-button"/>
399 400 401
                                </style>
                              </object>
                              <packing>
402
                                <property name="name">am</property>
403 404 405
                              </packing>
                            </child>
                            <child>
406 407
                              <object class="GtkButton" id="button_to_pm">
                                <property name="label" translatable="yes">PM</property>
408 409
                                <property name="visible">True</property>
                                <property name="can_focus">True</property>
410 411
                                <property name="receives_default">True</property>
                                <property name="valign">center</property>
412
                                <signal name="clicked" handler="dialog_am_pm_to_button_clicked_cb" object="CcNightLightDialog" swapped="no" />
413
                                <style>
414
                                  <class name="unpadded-button"/>
415 416 417
                                </style>
                              </object>
                              <packing>
418 419
                                <property name="name">pm</property>
                                <property name="position">1</property>
420 421 422
                              </packing>
                            </child>
                            <child>
423
                              <object class="GtkLabel">
424 425 426 427
                                <property name="visible">True</property>
                                <property name="can_focus">False</property>
                              </object>
                              <packing>
428 429
                                <property name="name">blank</property>
                                <property name="position">2</property>
430 431 432 433 434 435 436 437
                              </packing>
                            </child>
                          </object>
                        </child>
                      </object>
                      <packing>
                        <property name="expand">False</property>
                        <property name="fill">True</property>
438 439 440 441 442 443 444 445 446
                        <property name="pack_type">end</property>
                        <property name="position">2</property>
                      </packing>
                    </child>
                    <child>
                      <object class="GtkLabel">
                        <property name="visible">True</property>
                        <property name="can_focus">False</property>
                        <property name="halign">start</property>
447
                        <property name="valign">center</property>
448 449
                        <property name="margin_left">3</property>
                        <property name="label" translatable="yes">To</property>
450
                        <property name="mnemonic_widget">spinbutton_to_hours</property>
451 452 453 454 455 456 457 458 459
                        <style>
                          <class name="dim-label"/>
                        </style>
                      </object>
                      <packing>
                        <property name="expand">False</property>
                        <property name="fill">False</property>
                        <property name="pack_type">end</property>
                        <property name="position">3</property>
460 461 462
                      </packing>
                    </child>
                  </object>
463
                </child>
464 465 466 467 468 469 470
                <child>
                  <object class="GtkLabel">
                    <property name="visible">True</property>
                    <property name="can_focus">False</property>
                    <property name="halign">start</property>
                    <property name="hexpand">True</property>
                    <property name="label" translatable="yes">Color Temperature</property>
471
                    <property name="mnemonic_widget">scale_color_temperature</property>
472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494
                    <attributes>
                      <attribute name="weight" value="bold"/>
                    </attributes>
                  </object>
                </child>
                <child>
                  <object class="GtkScale" id="scale_color_temperature">
                    <property name="visible">True</property>
                    <property name="can_focus">True</property>
                    <property name="hexpand">True</property>
                    <property name="adjustment">adjustment_color_temperature</property>
                    <property name="inverted">True</property>
                    <property name="restrict_to_fill_level">False</property>
                    <property name="fill_level">1</property>
                    <property name="digits">0</property>
                    <property name="draw_value">False</property>
                    <property name="has_origin">False</property>
                    <property name="value_pos">bottom</property>
                    <style>
                      <class name="night-light-temperature"/>
                    </style>
                  </object>
                </child>
495 496 497 498 499 500
              </object>
            </child>
          </object>
        </child>
      </object>
    </child>
501 502 503 504 505 506 507
    <child type="titlebar">
      <object class="GtkHeaderBar">
        <property name="visible">True</property>
        <property name="can_focus">False</property>
        <property name="title" translatable="yes" comments="This is the redshift functionality where we suppress blue light when the sun has gone down">Night Light</property>
        <property name="show_close_button">True</property>
      </object>
508
    </child>
509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533
  </template>

  <object class="GtkAdjustment" id="adjustment_from_hours">
    <property name="upper">23</property>
    <property name="step_increment">1</property>
    <property name="page_increment">10</property>
    <signal name="value-changed" handler="dialog_time_from_value_changed_cb" object="CcNightLightDialog" swapped="no" />
  </object>
  <object class="GtkAdjustment" id="adjustment_from_minutes">
    <property name="upper">59</property>
    <property name="step_increment">1</property>
    <property name="page_increment">10</property>
    <signal name="value-changed" handler="dialog_time_from_value_changed_cb" object="CcNightLightDialog" swapped="no" />
  </object>
  <object class="GtkAdjustment" id="adjustment_to_hours">
    <property name="upper">23</property>
    <property name="step_increment">1</property>
    <property name="page_increment">10</property>
    <signal name="value-changed" handler="dialog_time_to_value_changed_cb" object="CcNightLightDialog" swapped="no" />
  </object>
  <object class="GtkAdjustment" id="adjustment_to_minutes">
    <property name="upper">59</property>
    <property name="step_increment">1</property>
    <property name="page_increment">10</property>
    <signal name="value-changed" handler="dialog_time_to_value_changed_cb" object="CcNightLightDialog" swapped="no" />
534
  </object>
535 536 537 538 539 540 541
  <object class="GtkAdjustment" id="adjustment_color_temperature">
    <property name="lower">3000</property>
    <property name="upper">6000</property>
    <property name="step_increment">100</property>
    <property name="page_increment">500</property>
    <signal name="value-changed" handler="dialog_color_temperature_value_changed_cb" object="CcNightLightDialog" swapped="no" />
  </object>
542
</interface>