aboutsummaryrefslogtreecommitdiff
path: root/README
blob: b51e110029117ad131aad1bc8b620e6079ef781d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
The indicator service file format
=================================

Unity's panel finds out about indicator by looking at indicator service
files in `/usr/share/unity/indicators`. These files have to have the same
name as the well-known D-Bus name that the corresponding service owns.

An indicator file is a normal key file (like desktop files).  It must have
an `[Indicator Service]` section, that must contain the service's name (`Name`)
and the object path at which its action group is found (`ObjectPath`). For
example:

  [Indicator Service]
  Name=indicator-example
  ObjectPath=/com/canonical/indicator/example

It should also contain a hint to where the indicator should appear in the panel:

  Position=70

The smaller the position, the further to the right (or left when RTL is
enabled) the indicator appears.

An indicator can only export one action group, but a menu for each profile
("desktop", "greeter", "phone") supports. There must be a section for each
of those profiles, containing the object path on which the menu is
exported:

  [desktop]
  ObjectPath=/com/canonical/indicator/example/desktop

  [greeter]
  ObjectPath=/com/canonical/indicator/example/desktop

  [phone]
  ObjectPath=/com/canonical/indicator/example/phone

Object paths can be reused for different profiles (the greeter uses the
same menu as the desktop in the above example).

There are no fallbacks. If a profile is not mentioned in the service file,
the indicator will not show up for that profile.