Blame platform-demos/C/image.c.page
|
Packit |
1470ea |
|
|
Packit |
1470ea |
|
|
Packit |
1470ea |
xmlns:its="http://www.w3.org/2005/11/its"
|
|
Packit |
1470ea |
xmlns:xi="http://www.w3.org/2001/XInclude"
|
|
Packit |
1470ea |
type="guide" style="task"
|
|
Packit |
1470ea |
id="image.c">
|
|
Packit |
1470ea |
<info>
|
|
Packit |
1470ea |
<title type="text">Image (C)</title>
|
|
Packit |
1470ea |
<link type="guide" xref="c#display-widgets"/>
|
|
Packit |
1470ea |
<revision version="0.1" date="2012-05-23" status="draft"/>
|
|
Packit |
1470ea |
|
|
Packit |
1470ea |
<credit type="author copyright">
|
|
Packit |
1470ea |
<name>Monica Kochofar</name>
|
|
Packit |
1470ea |
<email its:translate="no">monicakochofar@gmail.com</email>
|
|
Packit |
1470ea |
<years>2012</years>
|
|
Packit |
1470ea |
</credit>
|
|
Packit |
1470ea |
|
|
Packit |
1470ea |
<desc>A widget displaying an image</desc>
|
|
Packit |
1470ea |
</info>
|
|
Packit |
1470ea |
|
|
Packit |
1470ea |
<title>Image</title>
|
|
Packit |
1470ea |
<media type="image" mime="image/png" src="media/image.png"/>
|
|
Packit |
1470ea |
This GtkApplication displays an image file from the current directory.
|
|
Packit |
1470ea |
<note>
|
|
Packit |
1470ea |
If the image file isn't loaded successfully, the image will contain a "broken image" icon. The <file>filename.png</file> needs to be in the current directory for this code to work. Use your favorite picture!
|
|
Packit |
1470ea |
</note>
|
|
Packit |
1470ea |
|
|
Packit |
1470ea |
<xi:include href="samples/image.c" parse="text"><xi:fallback/></xi:include>
|
|
Packit |
1470ea |
|
|
Packit |
1470ea |
In this sample we used the following:
|
|
Packit |
1470ea |
|
|
Packit |
1470ea |
<list>
|
|
Packit |
1470ea |
<item><link href="http://developer.gnome.org/gtk3/3.4/GtkApplication.html">GtkApplication</link> </item>
|
|
Packit |
1470ea |
<item><link href="http://developer.gnome.org/gtk3/stable/GtkWindow.html">GtkWindow</link> </item>
|
|
Packit |
1470ea |
<item><link href="http://developer.gnome.org/gtk3/stable/GtkImage.html">GtkImage</link> </item>
|
|
Packit |
1470ea |
</list>
|
|
Packit |
1470ea |
</page>
|