Files
federated-calendar/data/ui/edit-dialog.ui
T
Georges Basile Stavracas Neto 8927e10ae0 edit-dialog: wrap in a scrolled window
As we're adding more and more widgets in the Edit dialog,
it is now growing too tall to fit normal screens. Thus, wrap
it in a scrolled window, and let the content height cover
75% of the main window at most.
2017-09-07 14:58:14 -03:00

690 lines
34 KiB
XML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<?xml version="1.0" encoding="UTF-8"?>
<interface>
<template class="GcalEditDialog" parent="GtkDialog">
<property name="can_focus">False</property>
<property name="resizable">False</property>
<property name="modal">True</property>
<property name="window_position">center-on-parent</property>
<property name="use_header_bar">1</property>
<property name="destroy_with_parent">True</property>
<property name="type_hint">dialog</property>
<child type="titlebar">
<object class="GtkHeaderBar" id="titlebar">
<property name="visible">True</property>
<child>
<object class="GtkButton" id="cancel_button">
<property name="label" translatable="yes">Cancel</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<signal name="clicked" handler="action_button_clicked" object="GcalEditDialog" swapped="no"/>
</object>
</child>
<child>
<object class="GtkImage" id="lock">
<property name="visible" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default|invert-boolean" />
<property name="icon_name">changes-prevent-symbolic</property>
<property name="icon_size">1</property>
</object>
</child>
<child type="title">
<object class="GtkMenuButton" id="sources_button">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="popover">sources_popover</property>
<property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<property name="tooltip-text" translatable="yes">Click to select the calendar</property>
<style>
<class name="flat"/>
<class name="sources-button"/>
</style>
<child>
<object class="GtkBox">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="spacing">6</property>
<child>
<object class="GtkBox" id="title_label_box">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="orientation">vertical</property>
<property name="valign">center</property>
<child>
<object class="GtkLabel" id="title_label">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="ellipsize">middle</property>
<property name="max_width_chars">40</property>
<property name="label" bind-source="summary_entry" bind-property="text" bind-flags="default" />
<style>
<class name="title"/>
</style>
</object>
</child>
<child>
<object class="GtkBox" id="subtitle_box">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="orientation">horizontal</property>
<property name="halign">center</property>
<child>
<object class="GtkImage" id="source_image">
<property name="visible">True</property>
<property name="can_focus">False</property>
<style>
<class name="calendar-color-image"/>
</style>
</object>
</child>
<child>
<object class="GtkLabel" id="subtitle_label">
<property name="visible">True</property>
<property name="can_focus">False</property>
<style>
<class name="subtitle"/>
</style>
</object>
</child>
<style>
<class name="subtitle"/>
</style>
</object>
</child>
</object>
</child>
<child>
<object class="GtkImage" id="pan_down_image">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="icon_name">pan-down-symbolic</property>
</object>
</child>
</object>
</child>
</object>
</child>
<child>
<object class="GtkButton" id="done_button">
<property name="label" translatable="yes">Done</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<signal name="clicked" handler="action_button_clicked" object="GcalEditDialog" swapped="no"/>
<style>
<class name="suggested-action"/>
</style>
</object>
<packing>
<property name="pack_type">end</property>
</packing>
</child>
</object>
</child>
<child internal-child="vbox">
<object class="GtkBox" id="dialog-vbox">
<property name="visible">true</property>
<property name="spacing">0</property>
<property name="border_width">0</property>
<child>
<object class="GtkScrolledWindow" id="scrolled_window">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="hscrollbar_policy">never</property>
<property name="min_content_height">400</property>
<property name="propagate_natural_height">true</property>
<child>
<object class="GtkGrid" id="main_grid">
<property name="visible">True</property>
<property name="border_width">18</property>
<property name="row_spacing">6</property>
<property name="column_spacing">12</property>
<child>
<object class="GtkLabel" id="summary_label">
<property name="visible">True</property>
<property name="xalign">1.0</property>
<property name="margin-top">12</property>
<property name="label" translatable="yes">Title</property>
<property name="ellipsize">end</property>
<property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<signal name="size-allocate" handler="fix_reminders_label_height_cb" object="reminders_label" swapped="no" after="yes" />
<style>
<class name="dim-label"/>
</style>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">0</property>
</packing>
</child>
<child>
<object class="GtkLabel" id="dates_label">
<property name="visible">True</property>
<property name="xalign">1.0</property>
<property name="margin-top">12</property>
<property name="label" translatable="yes">Date</property>
<property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<style>
<class name="dim-label"/>
</style>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">1</property>
</packing>
</child>
<child>
<object class="GtkLabel">
<property name="visible">True</property>
<property name="xalign">1.0</property>
<property name="margin-top">12</property>
<property name="label" translatable="yes">Repeat</property>
<property name="ellipsize">end</property>
<property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<style>
<class name="dim-label"/>
</style>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">4</property>
</packing>
</child>
<child>
<object class="GtkLabel" id="reminders_label">
<property name="visible">True</property>
<property name="xalign">1.0</property>
<property name="margin-top">12</property>
<property name="valign">start</property>
<property name="label" translatable="yes">Reminders</property>
<property name="ellipsize">end</property>
<property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<style>
<class name="dim-label"/>
</style>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">6</property>
</packing>
</child>
<child>
<object class="GtkLabel" id="notes_label">
<property name="visible">True</property>
<property name="xalign">1.0</property>
<property name="margin-top">12</property>
<property name="valign">start</property>
<property name="label" translatable="yes">Notes</property>
<property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<style>
<class name="dim-label"/>
</style>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">8</property>
</packing>
</child>
<child>
<object class="GtkLabel" id="location_label">
<property name="visible">True</property>
<property name="xalign">1.0</property>
<property name="margin-top">12</property>
<property name="label" translatable="yes">Location</property>
<property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<style>
<class name="dim-label"/>
</style>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">7</property>
</packing>
</child>
<child>
<object class="GtkEntry" id="summary_entry">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="hexpand">True</property>
<property name="activates_default">True</property>
<property name="margin-top">12</property>
<property name="editable" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<signal name="notify::text" handler="update_summary" object="GcalEditDialog" swapped="no"/>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">0</property>
<property name="width">4</property>
</packing>
</child>
<child>
<object class="GtkBox">
<property name="visible">True</property>
<property name="hexpand">True</property>
<property name="margin-top">12</property>
<property name="spacing">6</property>
<property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<child>
<object class="GcalDateSelector" id="start_date_selector">
<property name="visible">True</property>
<property name="can_focus">True</property>
<signal name="notify::date" handler="sync_datetimes" object="GcalEditDialog" swapped="yes" />
</object>
</child>
<child>
<object class="GtkLabel">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label">-</property>
</object>
</child>
<child>
<object class="GcalDateSelector" id="end_date_selector">
<property name="visible">True</property>
<property name="can_focus">True</property>
<signal name="notify::date" handler="sync_datetimes" object="GcalEditDialog" swapped="yes" />
</object>
</child>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">1</property>
<property name="width">4</property>
</packing>
</child>
<child>
<object class="GtkLabel" id="times_label">
<property name="visible">True</property>
<property name="xalign">1.0</property>
<property name="label" translatable="yes">Time</property>
<style>
<class name="dim-label"/>
</style>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">2</property>
</packing>
</child>
<child>
<object class="GtkBox">
<property name="visible">True</property>
<child>
<object class="GtkBox">
<property name="visible">True</property>
<property name="spacing">6</property>
<child>
<object class="GcalTimeSelector" id="start_time_selector">
<property name="visible">True</property>
<property name="can_focus">True</property>
<signal name="notify::time" handler="sync_datetimes" object="GcalEditDialog" swapped="yes" />
</object>
</child>
<child>
<object class="GtkLabel">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label">-</property>
</object>
</child>
<child>
<object class="GcalTimeSelector" id="end_time_selector">
<property name="visible">True</property>
<property name="can_focus">True</property>
<signal name="notify::time" handler="sync_datetimes" object="GcalEditDialog" swapped="yes" />
</object>
</child>
</object>
</child>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">2</property>
<property name="width">4</property>
</packing>
</child>
<child>
<object class="GtkCheckButton" id="all_day_check">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="margin-top">12</property>
<property name="draw_indicator">True</property>
<property name="label" translatable="yes">All Day</property>
<property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<signal name="toggled" handler="all_day_changed_cb" object="GcalEditDialog" swapped="no"/>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">3</property>
</packing>
</child>
<child>
<object class="GtkBox">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="margin-top">12</property>
<property name="spacing">6</property>
<property name="hexpand">True</property>
<property name="orientation">vertical</property>
<property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<child>
<object class="GtkListBox" id="alarms_listbox">
<property name="visible">False</property>
<property name="can_focus">False</property>
<property name="selection_mode">none</property>
<style>
<class name="background" />
</style>
</object>
</child>
<child>
<object class="GtkMenuButton" id="alarms_button">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="hexpand">True</property>
<property name="popover">alarms_popover</property>
<child>
<object class="GtkBox">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="orientation">horizontal</property>
<child>
<object class="GtkLabel">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="hexpand">True</property>
<property name="xalign">0.0</property>
<property name="label" translatable="yes">Add reminder…</property>
</object>
</child>
<child>
<object class="GtkImage">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="icon_name">pan-down-symbolic</property>
</object>
</child>
</object>
</child>
</object>
</child>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">6</property>
<property name="width">4</property>
</packing>
</child>
<!-- combo-box with options to define the recurrence-rules !-->
<child>
<object class="GtkComboBoxText" id="repeat_combo">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="margin-top">12</property>
<property name="hexpand">True</property>
<signal name="changed" handler="repeat_type_changed" object="GcalEditDialog" swapped="no"/>
<property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<items>
<item translatable="yes" id="no_repeat">No Repeat</item>
<item translatable="yes" id="daily">Daily</item>
<item translatable="yes" id="mon_fri">Monday – Friday</item>
<item translatable="yes" id="weekly">Weekly</item>
<item translatable="yes" id="monthly">Monthly</item>
<item translatable="yes" id="yearly">Yearly</item>
</items>
<property name="active_id">no_repeat</property>
<style>
<class name="background" />
</style>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">4</property>
<property name="width">4</property>
</packing>
</child>
<child>
<object class="GtkBox" id="repeat_limits_box">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="spacing">6</property>
<property name="hexpand">True</property>
<property name="orientation">horizontal</property>
<property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<child>
<object class="GtkComboBoxText" id="repeat_duration_combo">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="hexpand">True</property>
<signal name="changed" handler="repeat_duration_changed" object="GcalEditDialog" swapped="no"/>
<items>
<item translatable="yes" id="forever">Forever</item>
<item translatable="yes" id="number_of_occurrences_spin">No. of occurrences</item>
<item translatable="yes" id="until_date">Until Date</item>
</items>
<property name="active_id">forever</property>
<style>
<class name="background" />
</style>
</object>
</child>
<child>
<object class="GtkStack" id="repeat_duration_stack">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="halign">end</property>
<child>
<object class = "GtkSpinButton" id="number_of_occurrences_spin">
<property name="visible">True</property>
<property name="input_purpose">number</property>
</object>
</child>
<child>
<object class = "GcalDateSelector" id="until_date_selector">
<property name="visible">True</property>
</object>
</child>
<style>
<class name="background" />
</style>
</object>
</child>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">5</property>
<property name="width">4</property>
</packing>
</child>
<child>
<object class="GtkEntry" id="location_entry">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="margin-top">12</property>
<property name="secondary_icon_name">find-location-symbolic</property>
<property name="editable" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<signal name="notify::text" handler="update_location" object="GcalEditDialog" swapped="no"/>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">7</property>
<property name="width">4</property>
</packing>
</child>
<child>
<object class="GtkScrolledWindow">
<property name="min_content_height">120</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="margin-top">12</property>
<property name="vexpand">True</property>
<property name="shadow_type">in</property>
<child>
<object class="GtkTextView" id="notes_text">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="hexpand">True</property>
<property name="top_margin">6</property>
<property name="bottom_margin">6</property>
<property name="left_margin">6</property>
<property name="right_margin">6</property>
<property name="sensitive">True</property>
<property name="editable" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<property name="cursor_visible" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<property name="wrap_mode">GTK_WRAP_WORD_CHAR</property>
</object>
</child>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">8</property>
<property name="width">4</property>
</packing>
</child>
<child>
<object class="GtkButton" id="delete_button">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="margin-top">12</property>
<signal name="clicked" handler="action_button_clicked" object="GcalEditDialog" swapped="no"/>
<property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" bind-flags="default" />
<child>
<object class="GtkLabel" id="delete_label">
<property name="visible">True</property>
<property name="label" translatable="yes">Delete Event</property>
</object>
</child>
<style>
<class name="destructive-action"/>
</style>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">9</property>
</packing>
</child>
</object>
<packing>
<property name="expand">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
</child>
</object>
</child>
</template>
<object class="GtkPopover" id="sources_popover">
</object>
<object class="GtkPopoverMenu" id="alarms_popover">
<property name="can_focus">False</property>
<property name="width_request">175</property>
<child>
<object class="GtkBox">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="border_width">12</property>
<property name="orientation">vertical</property>
<child>
<object class="GtkModelButton" id="five_minutes_button">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="text" translatable="yes">5 minutes</property>
<signal name="clicked" handler="add_alarm_button_clicked" object="GcalEditDialog" swapped="no" />
</object>
</child>
<child>
<object class="GtkModelButton" id="ten_minutes_button">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="text" translatable="yes">10 minutes</property>
<signal name="clicked" handler="add_alarm_button_clicked" object="GcalEditDialog" swapped="no" />
</object>
</child>
<child>
<object class="GtkModelButton" id="thirty_minutes_button">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="text" translatable="yes">30 minutes</property>
<signal name="clicked" handler="add_alarm_button_clicked" object="GcalEditDialog" swapped="no" />
</object>
</child>
<child>
<object class="GtkModelButton" id="one_hour_button">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="text" translatable="yes">1 hour</property>
<signal name="clicked" handler="add_alarm_button_clicked" object="GcalEditDialog" swapped="no" />
</object>
</child>
<child>
<object class="GtkModelButton" id="one_day_button">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="text" translatable="yes">1 day</property>
<signal name="clicked" handler="add_alarm_button_clicked" object="GcalEditDialog" swapped="no" />
</object>
</child>
<child>
<object class="GtkModelButton" id="two_days_button">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="text" translatable="yes">2 days</property>
<signal name="clicked" handler="add_alarm_button_clicked" object="GcalEditDialog" swapped="no" />
</object>
</child>
<child>
<object class="GtkModelButton" id="three_days_button">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="text" translatable="yes">3 days</property>
<signal name="clicked" handler="add_alarm_button_clicked" object="GcalEditDialog" swapped="no" />
</object>
</child>
<child>
<object class="GtkModelButton" id="one_week_button">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="text" translatable="yes">1 week</property>
<signal name="clicked" handler="add_alarm_button_clicked" object="GcalEditDialog" swapped="no" />
</object>
</child>
</object>
</child>
</object>
<object class="GtkSizeGroup">
<property name="mode">vertical</property>
<widgets>
<widget name="cancel_button" />
<widget name="done_button" />
<widget name="sources_button" />
</widgets>
</object>
<object class="GtkSizeGroup">
<property name="mode">vertical</property>
<widgets>
<widget name="pan_down_image" />
<widget name="title_label_box" />
</widgets>
</object>
<object class="GtkSizeGroup">
<property name="mode">horizontal</property>
<widgets>
<widget name="end_date_selector" />
<widget name="end_time_selector" />
<widget name="start_date_selector" />
<widget name="start_time_selector" />
</widgets>
</object>
</interface>