Commit f1e4fd32 authored by Canek Peláez's avatar Canek Peláez
Browse files

Initial commit

parents
Loading
Loading
Loading
Loading

AUTHORS

0 → 100644
+1 −0
Original line number Diff line number Diff line
Canek Peláez Valdés	<canek@ciencias.unam.mx>

COPYING

0 → 100644
+674 −0

File added.

Preview size limit exceeded, changes collapsed.

README.md

0 → 100644
+5 −0
Original line number Diff line number Diff line
Gtk JSON
========

A small Gtk JSON viewer.
+92 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="UTF-8"?>
<interface>
  <requires lib="gtk" version="4.0"/>
  <object class="GListStore" id="nodes_model">
    <property name="item-type">GtkJsonApplicationNodeRow</property>
  </object>
  <menu id="gtkjson_main_menu">
    <section>
      <item>
        <attribute name="label">Open JSON...</attribute>
        <attribute name="action">app.open</attribute>
      </item>
      <item>
        <attribute name="label">About GtkJson...</attribute>
        <attribute name="action">app.about</attribute>
      </item>
    </section>
    <section>
      <item>
        <attribute name="label">Quit</attribute>
        <attribute name="action">app.quit</attribute>
      </item>
    </section>
  </menu>
  <template class="GtkJsonApplicationApplicationWindow" parent="GtkApplicationWindow">
    <property name="width-request">800</property>
    <property name="height-request">600</property>
    <signal name="close-request" handler="on_close_request" swapped="no"/>
    <child type="titlebar">
      <object class="GtkHeaderBar" id="header">
        <property name="title-widget">
          <object class="GtkBox">
            <property name="valign">center</property>
            <property name="spacing">1</property>
            <property name="orientation">vertical</property>
            <child>
              <object class="GtkLabel">
                <property name="label" translatable="yes">GtkJson</property>
                <property name="single-line-mode">true</property>
                <style>
                  <class name="title" />
                </style>
              </object>
            </child>
            <child>
              <object class="GtkLabel" id="subtitle">
                <property name="label" translatable="yes">GtkJson</property>
                <property name="single-line-mode">true</property>
                <style>
                  <class name="subtitle" />
                </style>
              </object>
            </child>
          </object>
        </property>
        <child type="end">
          <object class="GtkMenuButton" id="menu_button">
            <property name="primary">true</property>
            <property name="tooltip-text" translatable="yes">GtkJson menu</property>
            <property name="menu-model">gtkjson_main_menu</property>
            <child>
              <object class="GtkImage" id="menu_image">
                <property name="icon-name">open-menu-symbolic</property>
                <property name="icon-size">normal</property>
              </object>
            </child>
          </object>
        </child>
      </object>
    </child>
    <child>
      <object class="GtkScrolledWindow" id="json_scroll">
        <property name="has-frame">true</property>
        <child>
          <object class="GtkListView" id="nodes_list">
            <property name="model">
              <object class="GtkSingleSelection" id="nodes_selection" />
            </property>
            <property name="factory">
              <object class="GtkBuilderListItemFactory">
                <property name="resource">/mx/unam/GtkJson/node-row.ui</property>
              </object>
            </property>
          </object>
        </child>
        <style>
          <class name="content" />
        </style>
      </object>
    </child>
  </template>
</interface>
+8 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="UTF-8"?>
<gresources>
  <gresource prefix="/mx/unam/GtkJson">
    <file>style.css</file>
    <file preprocess="xml-stripblanks">application-window.ui</file>
    <file preprocess="xml-stripblanks">node-row.ui</file>
  </gresource>
</gresources>
Loading