Files
federated-calendar/data/ui/event-widget.ui
T
Georges Basile Stavracas Neto a853376629 event-widget: turn into a GtkBin subclass
The current GcalEventWidget implementation is a direct
GtkWidget subclass, which means we have to take care of
all the implementation details such as raising GdkWindows
and managing the drawing all by ourselves.

The event widget, however, can be easily described through
a GtkBuilder file. This would simplify the implementation
and makes us maintain less code.

Fix that by making GcalEventWidget a GtkBin subclass.
2017-09-14 13:26:28 -03:00

67 lines
2.8 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<interface>
<template class="GcalEventWidget" parent="GtkBin">
<child>
<object class="GtkEventBox" id="event_box">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="above_child">True</property>
<signal name="enter-notify-event" handler="enter_notify_event_cb" object="GcalEventWidget" swapped="no" />
<signal name="leave-notify-event" handler="leave_notify_event_cb" object="GcalEventWidget" swapped="no" />
<child>
<object class="GtkGrid" id="main_grid">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="column_spacing">6</property>
<property name="margin-top">1</property>
<property name="margin-bottom">1</property>
<property name="margin-start">4</property>
<property name="margin-end">4</property>
<property name="hexpand">False</property>
<child>
<object class="GtkLabel" id="hour_label">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="xalign">0.0</property>
<attributes>
<attribute name="weight" value="bold"/>
</attributes>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">0</property>
</packing>
</child>
<child>
<object class="GtkImage" id="alarm_icon">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="icon_name">alarm-symbolic</property>
<property name="pixel_size">12</property>
<property name="valign">center</property>
</object>
<packing>
<property name="left_attach">2</property>
<property name="top_attach">0</property>
</packing>
</child>
<child>
<object class="GtkLabel" id="summary_label">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="hexpand">True</property>
<property name="xalign">0</property>
<property name="ellipsize">end</property>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">0</property>
</packing>
</child>
</object>
</child>
</object>
</child>
</template>
</interface>