-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Icon pack support
Lawnchair supports two different types of icon sources: icon packs, and themed icon packs.
Note
Work in progress
For icon packs, Lawnchair supports the ADW launcher icon pack standard, a format used by many launchers and icon packs.
To be recognized as an icon pack, your app must declare an activity with at least one of the following intent filters in your AndroidManifest.xml
:
<activity android:name="[...]" android:exported="true">
<intent-filter>
<action android:name="org.adw.ActivityStarter.THEMES" />
</intent-filter>
<intent-filter>
<action android:name="com.novalauncher.THEME" />
</intent-filter>
</activity>
Icons are mapped to apps using a file called appfilter.xml
. This file must be located in one of these locations:
-
res/xml/appfilter.xml
(recommended) res/raw/appfilter.xml
assets/appfilter.xml
The file has the following structure:
<?xml version="1.0" encoding="utf-8"?>
<resources>
<!-- icons are added here -->
</resources>
drawable.xml
is a file that lists all icons that are included in the icon pack. This file is required for manual icon picking. The file lives in res/xml/drawable.xml
, and looks like this:
<?xml version="1.0" encoding="utf-8"?>
<resources>
<item drawable="messages" />
<category title="System" />
<item drawable="settings" />
<item drawable="settings_alt_1" />
</resources>
Every icon that should be available for manual icon picking must be listed in this file. You can optionally group icons by adding <category>
elements.
Icons are added to the appfilter.xml
file using the <item>
tag:
<item component="ComponentInfo{com.android.deskclock/com.android.deskclock.DeskClockTabActivity}"
drawable="clock" />
-
component
is the component name of the target activity. The short form is also supported if the class' package name starts with the app's package name:ComponentInfo{com.android.deskclock/.DeskClockTabActivity}
-
drawable
is the name of the icon drawable which must be located in theres/drawable/
folder (or any of its variants, e.g.res/drawable-hdpi/
)
Lawnchair also supports themed icon packs. These are a limited version of icon packs, using grayscale_icon_map.xml
This guide is based on Kvaesitso's guide to icon packs.