data directory are three files:
meson.build file describes the build rules for the program – we will
look at these later in Building the Application.
com.example.app_resources.desktop contains metadata about the
application that browsers and application launchers can use to show information
about the application, including its name, icon and the name of its executable
file. The contents of the file itself follows a simple format with many entries
[Desktop Entry] Name=App Resources Icon=com.example.app_resources Exec=app-resources Terminal=false Type=Application Categories= StartupNotify=false
Less obvious entries are
Exec entry holds the
file name of the executable used to run the application. This will be defined
in the build script we use. The
Terminal entry determines whether the
application should be run in a terminal program. We can ignore the other
entries for now.
com.example.app_resources.svg file is simply an SVG file:
We use an SVG file for convenience – it can be rescaled as needed by the user interface that shows it because the icon is stored in a vector file format. As a result, we do not need to provide bitmaps of different sizes.
In this part of the tutorial we looked at two files that provide information about the application (a desktop entry file) and a visual representation for it (an SVG icon file).
Next, we will see how the main program and the data files are put together when the application is built.