mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2025-01-12 13:30:19 +00:00
Getting started: Use <choices> in the schema
The use of a manually-specified enum is a little unusual. This is really meant to be done by <choices>.
This commit is contained in:
parent
99203f09f2
commit
b73027aa04
@ -1,17 +1,17 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<schemalist>
|
<schemalist>
|
||||||
<enum id="org.gtk.exampleapp.Transition">
|
|
||||||
<value value="0" nick="none"/>
|
|
||||||
<value value="1" nick="crossfade"/>
|
|
||||||
<value value="6" nick="slide-left-right"/>
|
|
||||||
</enum>
|
|
||||||
<schema path="/org/gtk/exampleapp/" id="org.gtk.exampleapp">
|
<schema path="/org/gtk/exampleapp/" id="org.gtk.exampleapp">
|
||||||
<key name="font" type="s">
|
<key name="font" type="s">
|
||||||
<default>'Monospace 12'</default>
|
<default>'Monospace 12'</default>
|
||||||
<summary>Font</summary>
|
<summary>Font</summary>
|
||||||
<description>The font to be used for content.</description>
|
<description>The font to be used for content.</description>
|
||||||
</key>
|
</key>
|
||||||
<key name="transition" enum="org.gtk.exampleapp.Transition">
|
<key name="transition" type="s">
|
||||||
|
<choices>
|
||||||
|
<choice value='none'/>
|
||||||
|
<choice value='crossfade'/>
|
||||||
|
<choice value='slide-left-right'/>
|
||||||
|
</choices>
|
||||||
<default>'none'</default>
|
<default>'none'</default>
|
||||||
<summary>Transition</summary>
|
<summary>Transition</summary>
|
||||||
<description>The transition to use when switching tabs.</description>
|
<description>The transition to use when switching tabs.</description>
|
||||||
|
@ -1,17 +1,17 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<schemalist>
|
<schemalist>
|
||||||
<enum id="org.gtk.exampleapp.Transition">
|
|
||||||
<value value="0" nick="none"/>
|
|
||||||
<value value="1" nick="crossfade"/>
|
|
||||||
<value value="6" nick="slide-left-right"/>
|
|
||||||
</enum>
|
|
||||||
<schema path="/org/gtk/exampleapp/" id="org.gtk.exampleapp">
|
<schema path="/org/gtk/exampleapp/" id="org.gtk.exampleapp">
|
||||||
<key name="font" type="s">
|
<key name="font" type="s">
|
||||||
<default>'Monospace 12'</default>
|
<default>'Monospace 12'</default>
|
||||||
<summary>Font</summary>
|
<summary>Font</summary>
|
||||||
<description>The font to be used for content.</description>
|
<description>The font to be used for content.</description>
|
||||||
</key>
|
</key>
|
||||||
<key name="transition" enum="org.gtk.exampleapp.Transition">
|
<key name="transition" type="s">
|
||||||
|
<choices>
|
||||||
|
<choice value='none'/>
|
||||||
|
<choice value='crossfade'/>
|
||||||
|
<choice value='slide-left-right'/>
|
||||||
|
</choices>
|
||||||
<default>'none'</default>
|
<default>'none'</default>
|
||||||
<summary>Transition</summary>
|
<summary>Transition</summary>
|
||||||
<description>The transition to use when switching tabs.</description>
|
<description>The transition to use when switching tabs.</description>
|
||||||
|
@ -1,17 +1,17 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<schemalist>
|
<schemalist>
|
||||||
<enum id="org.gtk.exampleapp.Transition">
|
|
||||||
<value value="0" nick="none"/>
|
|
||||||
<value value="1" nick="crossfade"/>
|
|
||||||
<value value="6" nick="slide-left-right"/>
|
|
||||||
</enum>
|
|
||||||
<schema path="/org/gtk/exampleapp/" id="org.gtk.exampleapp">
|
<schema path="/org/gtk/exampleapp/" id="org.gtk.exampleapp">
|
||||||
<key name="font" type="s">
|
<key name="font" type="s">
|
||||||
<default>'Monospace 12'</default>
|
<default>'Monospace 12'</default>
|
||||||
<summary>Font</summary>
|
<summary>Font</summary>
|
||||||
<description>The font to be used for content.</description>
|
<description>The font to be used for content.</description>
|
||||||
</key>
|
</key>
|
||||||
<key name="transition" enum="org.gtk.exampleapp.Transition">
|
<key name="transition" type="s">
|
||||||
|
<choices>
|
||||||
|
<choice value='none'/>
|
||||||
|
<choice value='crossfade'/>
|
||||||
|
<choice value='slide-left-right'/>
|
||||||
|
</choices>
|
||||||
<default>'none'</default>
|
<default>'none'</default>
|
||||||
<summary>Transition</summary>
|
<summary>Transition</summary>
|
||||||
<description>The transition to use when switching tabs.</description>
|
<description>The transition to use when switching tabs.</description>
|
||||||
|
@ -1,17 +1,17 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<schemalist>
|
<schemalist>
|
||||||
<enum id="org.gtk.exampleapp.Transition">
|
|
||||||
<value value="0" nick="none"/>
|
|
||||||
<value value="1" nick="crossfade"/>
|
|
||||||
<value value="6" nick="slide-left-right"/>
|
|
||||||
</enum>
|
|
||||||
<schema path="/org/gtk/exampleapp/" id="org.gtk.exampleapp">
|
<schema path="/org/gtk/exampleapp/" id="org.gtk.exampleapp">
|
||||||
<key name="font" type="s">
|
<key name="font" type="s">
|
||||||
<default>'Monospace 12'</default>
|
<default>'Monospace 12'</default>
|
||||||
<summary>Font</summary>
|
<summary>Font</summary>
|
||||||
<description>The font to be used for content.</description>
|
<description>The font to be used for content.</description>
|
||||||
</key>
|
</key>
|
||||||
<key name="transition" enum="org.gtk.exampleapp.Transition">
|
<key name="transition" type="s">
|
||||||
|
<choices>
|
||||||
|
<choice value='none'/>
|
||||||
|
<choice value='crossfade'/>
|
||||||
|
<choice value='slide-left-right'/>
|
||||||
|
</choices>
|
||||||
<default>'none'</default>
|
<default>'none'</default>
|
||||||
<summary>Transition</summary>
|
<summary>Transition</summary>
|
||||||
<description>The transition to use when switching tabs.</description>
|
<description>The transition to use when switching tabs.</description>
|
||||||
|
Loading…
Reference in New Issue
Block a user