File: README.md

package info (click to toggle)
ruby-gnome 4.3.4-1.0
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 22,316 kB
  • sloc: ruby: 55,217; ansic: 29,012; xml: 333; sh: 225; cpp: 45; makefile: 42
file content (13 lines) | stat: -rw-r--r-- 568 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
# Step 4: Add a menu

The original files are located in the following directory.

- https://gitlab.gnome.org/GNOME/gtk/-/blob/main/examples/application4

They are written in the C language and use `g_action_map_add_action entries`.
It is a convenience function for creating multiple GSimpleAction instances and adding them to a GActionMap.
If you write a program in C, it is the best way.

However, the program in this directory doesn't use `add_action_entries` method.
Instead, it uses `each` method of an array of action names.
The way above is flexible and simple.