Skip to content

Instantly share code, notes, and snippets.

@feliwir
Created April 20, 2022 07:12
Show Gist options
  • Save feliwir/c86582b5ae095832c39c353ae53fc3fa to your computer and use it in GitHub Desktop.
Save feliwir/c86582b5ae095832c39c353ae53fc3fa to your computer and use it in GitHub Desktop.
<?xml version="1.0" encoding="UTF-8"?>
<interface>
<requires lib="gtk" version="4.0" />
<object class="GListStore" id="image_list">
<property name="item-type">VoyagerExifImage</property>
</object>
<menu id="primary-menu">
<section>
<item>
<attribute name="label" translatable="yes">_Open</attribute>
<attribute name="action">win.open</attribute>
</item>
</section>
<section>
<item>
<attribute name="label" translatable="yes">_Help</attribute>
<attribute name="action">app.help</attribute>
</item>
<item>
<attribute name="label" translatable="yes">_About Voyager</attribute>
<attribute name="action">app.about</attribute>
</item>
</section>
</menu>
<template class="VoyagerWindow" parent="AdwApplicationWindow">
<property name="title" translatable="yes">Voyager</property>
<property name="default_width">800</property>
<property name="default_height">600</property>
<child>
<object class="AdwLeaflet" id="leaflet">
<child>
<object class="GtkBox">
<property name="orientation">vertical</property>
<child>
<object class="AdwHeaderBar">
<binding name="show-end-title-buttons">
<lookup name="folded">leaflet</lookup>
</binding>
<property name="title-widget">
<object class="AdwWindowTitle">
<property name="title">Images</property>
</object>
</property>
<child type="end">
<object class="GtkMenuButton" id="menu_button">
<property name="tooltip-text" translatable="yes">Menu</property>
<property name="menu_model">primary-menu</property>
<property name="icon_name">open-menu-symbolic</property>
<property name="tooltip-text" translatable="yes">Main Menu</property>
</object>
</child>
</object>
</child>
<child>
<object class="GtkScrolledWindow">
<property name="hscrollbar-policy">never</property>
<property name="vscrollbar-policy">automatic</property>
<child>
<object class="GtkGridView" id="image_grid">
<property name="model">
<object class="GtkNoSelection">
<property name="model">image_list</property>
</object>
</property>
<property name="factory">
<object class="GtkSignalListItemFactory">
<signal name="setup" handler="setup_listitem_cb" />
<signal name="bind" handler="bind_listitem_cb" />
</object>
</property>
<property name="min-columns">1</property>
<property name="max-columns">9</property>
<signal name="activate" handler="activate_listitem_cb" object="image_list" swapped="no" />
</object>
</child>
</object>
</child>
</object>
</child>
<child>
<object class="AdwLeafletPage">
<property name="navigatable">False</property>
<property name="child">
<object class="GtkSeparator" />
</property>
</object>
</child>
<child>
<object class="GtkBox">
<property name="orientation">vertical</property>
<child>
<object class="AdwHeaderBar">
<binding name="show-start-title-buttons">
<lookup name="folded">leaflet</lookup>
</binding>
<child>
<object class="GtkButton">
<binding name="visible">
<lookup name="folded">leaflet</lookup>
</binding>
<property name="icon-name">go-previous-symbolic</property>
</object>
</child>
<property name="title-widget">
<object class="AdwWindowTitle">
<property name="title">Map</property>
</object>
</property>
</object>
</child>
<child>
<object class="VoyagerImageMap" id="image_map">
<property name="halign">fill</property>
<property name="valign">fill</property>
</object>
</child>
</object>
</child>
</object>
</child>
</template>
</interface>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment