Skip to content

ProCraft for Android: An Android native painting app written in Rust

Rust

feat(ui): our own icons for the Actions panel's tabs

Joshc592be49f675
diff --git a/ATTRIBUTION.md b/ATTRIBUTION.md
index d622955..556fe95 100644
--- a/ATTRIBUTION.md
+++ b/ATTRIBUTION.md
@@ -13,7 +13,7 @@ them.
| `apps/procraft-android/android/app/src/main/assets/fonts/Inter-{Regular,Medium,SemiBold,Bold}.ttf` | Inter 4.1 (interface font) | The Inter Project Authors | <https://github.com/rsms/inter/releases/tag/v4.1> (`Inter-4.1.zip`, `extras/ttf/`; `SOURCE.md` beside them) | SIL OFL 1.1, `Inter-OFL.txt` |
| `apps/procraft-android/android/app/src/main/java/io/github/artcraftandroid/procraft/ui/Icons.kt` (the icons listed below as Phosphor) | Phosphor icons, @phosphor-icons/core 2.1.1, Fill weight | Phosphor Icons | <https://github.com/phosphor-icons/core>; each icon's paths moved and scaled into the frame it is shown in, at the size shown | MIT, [`LICENSE-phosphor.txt`](apps/procraft-android/android/app/src/main/assets/icons/LICENSE-phosphor.txt) |
| `apps/procraft-android/android/app/src/main/java/io/github/artcraftandroid/procraft/ui/LucideIcons.kt` (the same icons as Lucide draws them, kept beside them) | Lucide icons, lucide-static 1.63.0 | Lucide Icons and Contributors (those derived from Feather: Cole Bemis) | <https://github.com/lucide-icons/lucide>; each icon's paths moved and scaled into the frame it is shown in, at the size shown | ISC (Feather-derived also MIT), [`LICENSE-lucide.txt`](apps/procraft-android/android/app/src/main/assets/icons/LICENSE-lucide.txt) |
-| `assets/icons/procraft/*.svg`, and in `apps/procraft-android/android/app/src/main/java/io/github/artcraftandroid/procraft/ui/Icons.kt` the bar's icons (`Actions`, `Adjustments`, `Selection`, `Transform`, `Brush`, `Smudge`, `Erase`, `Layers`, `Undo`, `Redo`) | ProCraft's own interface icons | ProCraft contributors | Original work, drawn from the idea to [`docs/icons/STYLE_GUIDE.md`](docs/icons/STYLE_GUIDE.md) by `tools/icons/draw_icons.py`; placed by the measured slots in `assets/icons/slots.tsv` | MIT OR Apache-2.0 |
+| `assets/icons/procraft/*.svg`, and in `apps/procraft-android/android/app/src/main/java/io/github/artcraftandroid/procraft/ui/Icons.kt` the bar's icons (`Actions`, `Adjustments`, `Selection`, `Transform`, `Brush`, `Smudge`, `Erase`, `Layers`, `Undo`, `Redo`) and the Actions panel's tabs (`TabAdd`, `TabCanvas`, `TabShare`, `TabVideo`, `TabPrefs`, `TabHelp`) | ProCraft's own interface icons | ProCraft contributors | Original work, drawn from the idea to [`docs/icons/STYLE_GUIDE.md`](docs/icons/STYLE_GUIDE.md) by `tools/icons/draw_icons.py`; placed by the measured slots in `assets/icons/slots.tsv` | MIT OR Apache-2.0 |
| `apps/procraft-android/android/app/src/main/java/io/github/artcraftandroid/procraft/ui/Icons.kt` (every other icon) | Interface icons | ProCraft contributors | Original work, on a 24-unit grid | MIT OR Apache-2.0 |
| `apps/procraft-android/android/app/src/main/assets/environments/*.hdr` | 3D view light panoramas (11), halved to 512 x 256 and scaled by `tools/env/make_env.py` | Sergej Majboroda, Greg Zaal, Andreas Mischok, Rico Cilliers (per file in the folder's `README.md`) | <https://polyhaven.com> | CC0 1.0 |
| `assets/app-icon/procraft-{1024,512}.png`, `apps/procraft-android/android/app/src/main/res/drawable-*dpi/ic_launcher_{foreground,monochrome}.png`, `apps/procraft-android/android/app/src/main/res/drawable-nodpi/procraft_mark.png`, `apps/procraft-android/android/app/src/main/res/mipmap-anydpi/ic_launcher.xml` | App icon: a paintbrush in a warm-to-cool blend on black | ProCraft contributors | Original work, drawn in code by `tools/app-icon/make_icon.py`; see [`assets/app-icon/README.md`](assets/app-icon/README.md) | MIT OR Apache-2.0 |
@@ -79,12 +79,6 @@ Each with the Phosphor icon it is (Fill weight):
- `Sweep`: `broom`
- `CardCompact`: `rows`
- `CardStack`: `cards`
-- `TabAdd`: `plus`
-- `TabCanvas`: `frame-corners`
-- `TabShare`: `export`
-- `TabVideo`: `video`
-- `TabPrefs`: `toggle-right`
-- `TabHelp`: `question`
- `FolderFill`: `folder`
- `Freeform`: `arrows-out-line-horizontal`
- `Uniform`: `arrows-out`
diff --git a/apps/procraft-android/android/app/src/main/java/io/github/artcraftandroid/procraft/ui/Icons.kt b/apps/procraft-android/android/app/src/main/java/io/github/artcraftandroid/procraft/ui/Icons.kt
index 259aa06..19c5e3d 100644
--- a/apps/procraft-android/android/app/src/main/java/io/github/artcraftandroid/procraft/ui/Icons.kt
+++ b/apps/procraft-android/android/app/src/main/java/io/github/artcraftandroid/procraft/ui/Icons.kt
@@ -392,10 +392,10 @@ object PcIcons {
val More by lazy { solid("more", "M4 10.3a1.7 1.7 0 1 0 0 3.4a1.7 1.7 0 1 0 0-3.4z", "M12 10.3a1.7 1.7 0 1 0 0 3.4a1.7 1.7 0 1 0 0-3.4z", "M20 10.3a1.7 1.7 0 1 0 0 3.4a1.7 1.7 0 1 0 0-3.4z") }
val CardCompact by lazy { phosphor("cardcompact", 21f, 32f, "M 18.55,18.01 l 0,3.35 a 1.34,1.34 0 0,1-1.34,1.34 L 3.8,22.7 a 1.34,1.34 0 0,1-1.34,-1.34 L 2.45,18.01 a 1.34,1.34 0 0,1 1.34,-1.34 L 17.2,16.67 A 1.34,1.34 0 0,1 18.55,18.01 Z M 17.2,9.3 L 3.8,9.3 A 1.34,1.34 0 0,0 2.45,10.64 l 0,3.35 a 1.34,1.34 0 0,0 1.34,1.34 L 17.2,15.33 a 1.34,1.34 0 0,0 1.34,-1.34 L 18.55,10.64 A 1.34,1.34 0 0,0 17.2,9.3 Z") }
val CardStack by lazy { phosphor("cardstack", 21f, 32f, "M 16.28,12.49 L 16.28,22.26 a 1.4,1.4 0 0,1-1.4,1.4 L 2.32,23.65 a 1.4,1.4 0 0,1-1.4,-1.4 L 0.93,12.49 A 1.4,1.4 0 0,1 2.32,11.09 L 14.88,11.09 A 1.4,1.4 0 0,1 16.28,12.49 Z m 1.4,-4.19 L 4.42,8.3 a 0.7,0.7 0 0,0 0,1.4 L 17.68,9.7 L 17.68,20.16 a 0.7,0.7 0 0,0 1.4,0 L 19.07,9.7 A 1.4,1.4 0 0,0 17.68,8.3 Z") }
- val TabAdd by lazy { phosphor("tabadd", 50f, "M 33.31,14.63 L 16.34,14.63 A 1.7,1.7 0 0,0 14.64,16.33 L 14.64,33.3 a 1.7,1.7 0 0,0 1.7,1.7 L 33.31,35 a 1.7,1.7 0 0,0 1.7,-1.7 L 35.01,16.33 A 1.7,1.7 0 0,0 33.31,14.63 Z M 30.76,25.67 L 25.67,25.67 l 0,5.09 a 0.85,0.85 0 0,1-1.7,0 L 23.98,25.67 L 18.89,25.67 a 0.85,0.85 0 0,1 0,-1.7 l 5.09,0 L 23.98,18.88 a 0.85,0.85 0 0,1 1.7,0 l 0,5.09 l 5.09,0 a 0.85,0.85 0 0,1 0,1.7 Z") }
- val TabCanvas by lazy { phosphor("tabcanvas", 50f, "M 34.84,14.48 L 15.65,14.48 A 1.74,1.74 0 0,0 13.91,16.23 L 13.91,31.93 a 1.74,1.74 0 0,0 1.74,1.74 L 34.84,33.67 a 1.74,1.74 0 0,0 1.74,-1.74 L 36.59,16.23 A 1.74,1.74 0 0,0 34.84,14.48 Z M 20.88,31.06 L 17.39,31.06 a 0.87,0.87 0 0,1-0.87,-0.87 L 16.52,26.7 a 0.87,0.87 0 0,1 1.74,0 l 0,2.62 L 20.88,29.31 a 0.87,0.87 0 0,1 0,1.74 Z m 13.08,-9.6 a 0.87,0.87 0 0,1-1.74,0 L 32.22,18.85 L 29.61,18.85 a 0.87,0.87 0 0,1 0,-1.74 l 3.49,0 a 0.87,0.87 0 0,1 0.87,0.87 Z") }
- val TabShare by lazy { phosphor("tabshare", 50f, "M 34.38,20.97 l 0,10.01 a 1.67,1.67 0 0,1-1.67,1.67 L 17.69,32.65 a 1.67,1.67 0 0,1-1.67,-1.67 L 16.02,20.97 A 1.67,1.67 0 0,1 17.69,19.31 l 6.67,0 l 0,5 a 0.83,0.83 0 0,0 1.67,0 L 26.03,19.31 l 6.67,0 A 1.67,1.67 0 0,1 34.38,20.97 Z M 26.03,13.81 l 2.75,2.75 a 0.83,0.83 0 0,0 1.18,-1.18 l-4.17,-4.17 a 0.83,0.83 0 0,0-1.18,0 l-4.17,4.17 A 0.83,0.83 0 0,0 21.62,16.56 L 24.37,13.81 L 24.37,19.31 l 1.67,0 Z") }
- val TabVideo by lazy { phosphor("tabvideo", 50f, "M 35.86,31.46 a 0.72,0.72 0 0,1-0.72,0.72 L 17.83,32.18 a 0.72,0.72 0 0,1 0,-1.44 L 35.14,30.74 A 0.72,0.72 0 0,1 35.86,31.46 Z m 0,-13.7 L 35.86,27.86 a 1.44,1.44 0 0,1-1.44,1.44 L 18.55,29.3 a 1.44,1.44 0 0,1-1.44,-1.44 L 17.11,17.76 A 1.44,1.44 0 0,1 18.55,16.32 L 34.42,16.32 A 1.44,1.44 0 0,1 35.86,17.76 Z m-6.13,5.05 a 0.72,0.72 0 0,0-0.31,-0.59 l-3.61,-2.52 A 0.72,0.72 0 0,0 24.68,20.28 l 0,5.05 a 0.72,0.72 0 0,0 1.14,0.59 l 3.61,-2.52 A 0.72,0.72 0 0,0 29.73,22.81 Z") }
+ val TabAdd by lazy { ours("tabadd", 50f, "M23.41 33.72L23.51 34.12L23.64 34.37L23.82 34.58L24.15 34.83L24.55 34.97L24.82 35L25.1 34.97L25.5 34.83L25.83 34.58L26.01 34.37L26.14 34.12L26.22 33.85L26.25 33.58L26.25 26.24L33.73 26.23L34.13 26.13L34.38 26L34.6 25.82L34.77 25.6L34.91 25.36L35.01 24.95L35.01 24.67L34.95 24.4L34.85 24.14L34.69 23.91L34.49 23.71L34.26 23.56L33.87 23.41L33.59 23.39L26.25 23.39L26.24 15.91L26.14 15.5L26.01 15.26L25.83 15.04L25.5 14.79L25.24 14.68L24.96 14.63L24.69 14.63L24.41 14.68L24.03 14.86L23.82 15.04L23.64 15.26L23.51 15.5L23.43 15.77L23.4 16.05L23.4 23.39L15.92 23.39L15.52 23.5L15.27 23.63L15.05 23.8L14.88 24.02L14.74 24.27L14.64 24.67L14.64 24.95L14.7 25.22L14.8 25.48L14.96 25.72L15.16 25.91L15.39 26.07L15.78 26.21L16.06 26.24L23.4 26.24Z") }
+ val TabCanvas by lazy { ours("tabcanvas", 50f, "M35.86 15.96L35.64 15.55L35.34 15.18L34.98 14.88L34.56 14.66L34.11 14.53L33.65 14.48L16.85 14.48L16.38 14.53L15.93 14.66L15.51 14.88L15.15 15.18L14.85 15.55L14.63 15.96L14.49 16.41L14.45 16.88L14.45 31.28L14.49 31.75L14.63 32.2L14.85 32.61L15.15 32.98L15.51 33.28L15.93 33.5L16.38 33.63L16.85 33.68L33.65 33.68L34.11 33.63L34.56 33.5L34.98 33.28L35.34 32.98L35.64 32.61L35.86 32.2L36 31.75L36.05 31.28L36.05 16.88L36 16.41ZM33.4 30.85L33.33 30.97L33.17 31.04L17.33 31.04L17.16 30.97L17.09 30.8L17.09 17.36L17.16 17.19L17.33 17.12L33.17 17.12L33.33 17.19L33.41 17.36ZM31.72 21.01L31.92 20.78L32.07 20.51L32.17 20.22L32.2 19.92L32.15 19.47L32.04 19.18L31.88 18.92L31.67 18.7L31.42 18.52L30.99 18.36L30.69 18.32L30.38 18.34L30.09 18.42L29.81 18.56L18.77 27.15L18.57 27.38L18.42 27.65L18.3 28.09L18.31 28.54L18.39 28.84L18.53 29.11L18.71 29.35L18.94 29.55L19.21 29.71L19.5 29.8L19.8 29.84L20.11 29.82L20.4 29.74L20.68 29.6Z") }
+ val TabShare by lazy { ours("tabshare", 50f, "M25.43 12.59L25.2 12.52L25.04 12.55L24.91 12.64L20.86 16.85L20.78 16.98L20.75 17.14L20.82 17.36L20.93 17.46L21.07 17.52L24 17.53L24.01 25.03L24.05 25.26L24.14 25.48L24.27 25.67L24.44 25.84L24.64 25.97L24.85 26.06L25.2 26.11L25.43 26.09L25.66 26.02L25.87 25.91L26.05 25.76L26.2 25.58L26.31 25.37L26.39 25.03L26.4 17.53L29.33 17.52L29.53 17.42L29.62 17.29L29.65 17.14L29.62 16.98L29.54 16.85ZM16.04 30.14L16.11 30.36L16.22 30.57L16.46 30.83L16.76 31.01L17.1 31.1L33.18 31.1L33.42 31.08L33.64 31.01L33.94 30.83L34.18 30.57L34.33 30.25L34.37 30.02L34.38 22.42L34.36 22.19L34.29 21.96L34.11 21.66L33.85 21.42L33.53 21.27L33.3 21.23L33.07 21.23L32.72 21.31L32.42 21.49L32.19 21.75L32.04 22.07L31.99 22.42L31.99 28.71L18.41 28.71L18.41 22.42L18.39 22.19L18.32 21.96L18.14 21.66L17.98 21.49L17.78 21.36L17.56 21.27L17.33 21.23L17.1 21.23L16.76 21.31L16.46 21.49L16.29 21.66L16.11 21.96L16.03 22.3L16.02 29.9Z") }
+ val TabVideo by lazy { ours("tabvideo", 50f, "M29.9 20.41L29.79 20.04L29.61 19.7L29.36 19.4L29.06 19.15L28.72 18.97L28.35 18.86L27.97 18.82L19.08 18.82L18.7 18.86L18.33 18.97L17.99 19.15L17.69 19.4L17.44 19.7L17.26 20.04L17.15 20.41L17.11 20.8L17.11 27.7L17.15 28.09L17.26 28.46L17.44 28.8L17.69 29.1L17.99 29.35L18.33 29.53L18.7 29.64L19.08 29.68L27.97 29.68L28.35 29.64L28.72 29.53L29.06 29.35L29.36 29.1L29.61 28.8L29.79 28.46L29.9 28.09L29.94 27.7L29.94 20.8ZM31.71 23.87L31.6 24.08L31.57 24.19L31.6 24.42L31.71 24.63L34.9 27.22L35.11 27.33L35.35 27.35L35.58 27.27L35.75 27.1L35.81 27L35.86 26.76L35.86 21.74L35.81 21.5L35.67 21.31L35.47 21.18L35.35 21.15L35.11 21.17L35 21.21Z") }
/** The Lighting Studio's environments, each its own small picture (24 grid). */
// a studio lamp: a round light in its square housing
val EnvStudio by lazy {
@@ -462,8 +462,8 @@ object PcIcons {
viewport = 50f,
)
}
- val TabPrefs by lazy { phosphor("tabprefs", 50f, "M 31.06,14.9 L 19.08,14.9 a 8.98,8.98 0 0,0 0,17.97 l 11.98,0 a 8.98,8.98 0 0,0 0,-17.97 Z m 0,13.97 a 4.99,4.99 0 1,1 4.99,-4.99 A 4.99,4.99 0 0,1 31.06,28.87 Z") }
- val TabHelp by lazy { phosphor("tabhelp", 50f, "M 25.01,13.24 A 10.49,10.49 0 1,0 35.5,23.73 A 10.5,10.5 0 0,0 25.01,13.24 Z m 0,16.94 a 1.21,1.21 0 1,1 1.21,-1.21 A 1.21,1.21 0 0,1 25.01,30.18 Z m 0.81,-4.91 L 25.82,25.34 a 0.81,0.81 0 0,1-1.61,0 l 0,-0.81 a 0.81,0.81 0 0,1 0.81,-0.81 c 1.33,0 2.42,-0.91 2.42,-2.02 s-1.09,-2.02-2.42,-2.02 s-2.42,0.91-2.42,2.02 l 0,0.4 a 0.81,0.81 0 0,1-1.61,0 l 0,-0.4 c 0,-2 1.81,-3.63 4.03,-3.63 s 4.03,1.63 4.03,3.63 C 29.05,23.46 27.66,24.93 25.82,25.27 Z") }
+ val TabPrefs by lazy { ours("tabprefs", 50f, "M33.6 31.78L34.37 31.59L35.11 31.32L35.83 30.98L36.5 30.58L37.14 30.11L37.72 29.57L38.25 28.99L38.72 28.36L39.13 27.68L39.47 26.96L39.73 26.22L39.93 25.45L40.04 24.67L40.08 23.88L40.04 23.1L39.93 22.32L39.73 21.55L39.47 20.81L39.13 20.09L38.72 19.41L38.25 18.78L37.72 18.2L37.14 17.66L36.5 17.19L35.83 16.79L35.11 16.45L34.37 16.18L33.6 15.99L32.82 15.88L32.03 15.84L18.11 15.84L17.32 15.88L16.54 15.99L15.77 16.18L15.03 16.45L14.31 16.79L13.64 17.19L13 17.66L12.42 18.2L11.89 18.78L11.42 19.41L11.01 20.09L10.67 20.81L10.41 21.55L10.21 22.32L10.1 23.1L10.06 23.88L10.1 24.67L10.21 25.45L10.41 26.22L10.67 26.96L11.01 27.68L11.42 28.36L11.89 28.99L12.42 29.57L13 30.11L13.64 30.58L14.31 30.98L15.03 31.32L15.77 31.59L16.54 31.78L17.32 31.89L18.11 31.93L32.03 31.93L32.82 31.89ZM17.62 28.81L16.67 28.62L15.77 28.25L15.36 28L14.61 27.39L13.99 26.64L13.53 25.78L13.25 24.85L13.18 24.37L13.15 23.88L13.25 22.92L13.53 21.99L13.99 21.13L14.61 20.38L15.36 19.77L16.21 19.31L16.67 19.15L17.62 18.96L18.11 18.93L32.03 18.93L33 19.03L33.93 19.31L34.78 19.77L35.17 20.06L35.86 20.74L36.15 21.13L36.4 21.55L36.77 22.45L36.96 23.4L36.96 24.37L36.77 25.32L36.4 26.22L35.86 27.03L35.17 27.71L34.37 28.25L33.47 28.62L32.52 28.81L32.03 28.84ZM35.73 23.52L35.59 22.81L35.31 22.13L34.9 21.53L34.39 21.01L33.78 20.61L33.11 20.33L32.4 20.19L31.67 20.19L30.96 20.33L30.28 20.61L29.68 21.01L29.16 21.53L28.76 22.13L28.48 22.81L28.34 23.52L28.34 24.25L28.48 24.96L28.76 25.64L29.16 26.24L29.68 26.76L30.28 27.16L30.96 27.44L31.67 27.58L32.4 27.58L33.11 27.44L33.78 27.16L34.39 26.76L34.9 26.24L35.31 25.64L35.59 24.96L35.73 24.25Z") }
+ val TabHelp by lazy { ours("tabhelp", 50f, "M23.45 19.87L23.82 19.48L24.29 19.21L24.81 19.08L25.35 19.1L25.86 19.26L26.31 19.56L26.66 19.98L26.88 20.47L26.9 20.59L24.26 23.42L24.13 23.64L24.05 23.88L23.81 25.8L23.83 26.03L23.89 26.26L24.06 26.57L24.23 26.74L24.42 26.88L24.63 26.97L24.87 27.02L25.1 27.03L25.33 26.99L25.56 26.9L25.76 26.78L26 26.52L26.12 26.32L26.21 25.98L26.37 24.69L29.04 21.83L29.19 21.63L29.3 21.41L29.37 21.04L29.33 20.48L29.22 19.89L28.95 19.16L28.66 18.63L28.4 18.27L27.99 17.83L27.52 17.45L26.85 17.06L26.28 16.84L25.69 16.71L25.08 16.66L24.64 16.67L24.04 16.76L23.46 16.94L22.77 17.28L22.27 17.63L21.83 18.04L21.55 18.38L21.22 18.89L20.91 19.55L20.86 19.78L20.86 20.01L20.9 20.25L20.98 20.47L21.11 20.67L21.27 20.84L21.46 20.98L21.68 21.07L21.91 21.12L22.15 21.13L22.49 21.05L22.7 20.95L22.89 20.8L23.11 20.52L23.3 20.09ZM35.05 20.69L34.7 19.72L34.26 18.79L33.73 17.9L33.12 17.08L32.43 16.32L31.67 15.62L30.84 15.01L29.96 14.48L29.03 14.04L28.06 13.7L27.06 13.45L26.04 13.3L25.02 13.24L23.99 13.3L22.97 13.45L21.97 13.7L21 14.04L20.07 14.48L19.19 15.01L18.36 15.62L17.6 16.32L16.91 17.08L16.3 17.9L15.77 18.79L15.33 19.72L14.98 20.69L14.73 21.68L14.58 22.7L14.53 23.73L14.58 24.76L14.73 25.78L14.98 26.77L15.33 27.74L15.77 28.67L16.3 29.56L16.91 30.38L17.6 31.14L18.36 31.84L19.19 32.45L20.07 32.98L21 33.42L21.97 33.76L22.97 34.01L23.99 34.16L25.02 34.22L26.04 34.16L27.06 34.01L28.06 33.76L29.03 33.42L29.96 32.98L30.84 32.45L31.67 31.84L32.43 31.14L33.12 30.38L33.73 29.56L34.26 28.67L34.7 27.74L35.05 26.77L35.3 25.78L35.45 24.76L35.5 23.73L35.45 22.7L35.3 21.68ZM33.04 26.16L32.76 26.94L32.41 27.68L31.99 28.39L31.5 29.05L30.95 29.66L30.34 30.21L29.68 30.7L28.97 31.13L28.22 31.48L27.45 31.76L26.65 31.96L25.84 32.08L25.02 32.12L24.19 32.08L23.38 31.96L22.58 31.76L21.81 31.48L21.06 31.13L20.35 30.7L19.69 30.21L19.08 29.66L18.53 29.05L18.04 28.39L17.62 27.68L17.27 26.94L16.99 26.16L16.79 25.37L16.67 24.55L16.63 23.73L16.67 22.91L16.79 22.09L16.99 21.3L17.27 20.52L17.62 19.78L18.04 19.07L18.53 18.41L19.08 17.8L19.69 17.25L20.35 16.76L21.06 16.33L21.81 15.98L22.58 15.7L23.38 15.5L24.19 15.38L25.02 15.34L25.84 15.38L26.65 15.5L27.45 15.7L28.22 15.98L28.97 16.33L29.68 16.76L30.34 17.25L30.95 17.8L31.5 18.41L31.99 19.07L32.41 19.78L32.76 20.52L33.04 21.3L33.24 22.09L33.36 22.91L33.4 23.73L33.36 24.55L33.24 25.37ZM26.36 28.95L26.16 28.56L25.85 28.25L25.66 28.13L25.45 28.05L25.02 27.98L24.58 28.05L24.18 28.25L23.87 28.56L23.75 28.75L23.62 29.17L23.62 29.61L23.67 29.83L23.87 30.22L24.18 30.54L24.37 30.65L24.58 30.74L25.02 30.81L25.45 30.74L25.66 30.65L26.02 30.39L26.28 30.03L26.41 29.61L26.41 29.17Z") }
val Tick by lazy { outline("tick", 3.2f, "M5.5 12.5l4 4 9-9") }
val MenuTick by lazy { outline("menu-tick", 2.1f, "M5.5 12.5l4 4 9-9") }
val BrushSet by lazy { solid("brush-set", "M3.5 18.5c3.4-6.6 8.6-10.4 17-11.5-4.4 2.2-7.6 6-9.6 11.2-2.4-.6-4.8-.4-7.4.3z") }
diff --git a/assets/icons/procraft/tabadd.svg b/assets/icons/procraft/tabadd.svg
new file mode 100644
index 0000000..73c7585
--- /dev/null
+++ b/assets/icons/procraft/tabadd.svg
@@ -0,0 +1,4 @@
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
+ <!-- ProCraft tabadd icon: original, drawn by tools/icons/draw_icons.py. MIT OR Apache-2.0. -->
+ <path fill="currentColor" fill-rule="evenodd" d="M10.71 20.13L10.8 20.5L10.92 20.72L11.08 20.92L11.39 21.15L11.75 21.28L12 21.3L12.25 21.28L12.61 21.15L12.92 20.92L13.08 20.72L13.2 20.5L13.28 20.25L13.3 20L13.3 13.3L20.13 13.29L20.5 13.2L20.72 13.08L20.92 12.92L21.08 12.72L21.2 12.5L21.29 12.13L21.29 11.87L21.24 11.62L21.15 11.39L21 11.18L20.82 11L20.61 10.85L20.25 10.72L20 10.7L13.3 10.7L13.29 3.87L13.2 3.5L13.08 3.28L12.92 3.08L12.61 2.85L12.38 2.76L12.13 2.71L11.87 2.71L11.62 2.76L11.28 2.92L11.08 3.08L10.92 3.28L10.8 3.5L10.72 3.75L10.7 4L10.7 10.7L3.87 10.71L3.5 10.8L3.28 10.92L3.08 11.08L2.92 11.28L2.8 11.5L2.71 11.87L2.71 12.13L2.76 12.38L2.85 12.61L3 12.82L3.18 13L3.39 13.15L3.75 13.28L4 13.3L10.7 13.3Z"/>
+</svg>
diff --git a/assets/icons/procraft/tabcanvas.svg b/assets/icons/procraft/tabcanvas.svg
new file mode 100644
index 0000000..673daf2
--- /dev/null
+++ b/assets/icons/procraft/tabcanvas.svg
@@ -0,0 +1,4 @@
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
+ <!-- ProCraft tabcanvas icon: original, drawn by tools/icons/draw_icons.py. MIT OR Apache-2.0. -->
+ <path fill="currentColor" fill-rule="evenodd" d="M20.85 5.23L20.66 4.89L20.41 4.59L20.11 4.34L19.77 4.15L19.39 4.04L19 4L5 4L4.61 4.04L4.23 4.15L3.89 4.34L3.59 4.59L3.34 4.89L3.15 5.23L3.04 5.61L3 6L3 18L3.04 18.39L3.15 18.77L3.34 19.11L3.59 19.41L3.89 19.66L4.23 19.85L4.61 19.96L5 20L19 20L19.39 19.96L19.77 19.85L20.11 19.66L20.41 19.41L20.66 19.11L20.85 18.77L20.96 18.39L21 18L21 6L20.96 5.61ZM18.8 17.64L18.74 17.74L18.6 17.8L5.4 17.8L5.26 17.74L5.2 17.6L5.2 6.4L5.26 6.26L5.4 6.2L18.6 6.2L18.74 6.26L18.8 6.4ZM17.39 9.44L17.56 9.25L17.69 9.03L17.77 8.79L17.8 8.53L17.75 8.16L17.66 7.92L17.53 7.7L17.35 7.52L17.14 7.37L16.79 7.23L16.53 7.2L16.28 7.22L16.03 7.29L15.81 7.4L6.61 14.56L6.44 14.75L6.31 14.97L6.21 15.34L6.22 15.72L6.29 15.97L6.4 16.19L6.56 16.39L6.75 16.56L6.97 16.69L7.21 16.77L7.47 16.8L7.72 16.78L7.97 16.71L8.19 16.6Z"/>
+</svg>
diff --git a/assets/icons/procraft/tabhelp.svg b/assets/icons/procraft/tabhelp.svg
new file mode 100644
index 0000000..3509b3e
--- /dev/null
+++ b/assets/icons/procraft/tabhelp.svg
@@ -0,0 +1,4 @@
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
+ <!-- ProCraft tabhelp icon: original, drawn by tools/icons/draw_icons.py. MIT OR Apache-2.0. -->
+ <path fill="currentColor" fill-rule="evenodd" d="M10.51 8.31L10.86 7.94L11.31 7.69L11.81 7.56L12.32 7.58L12.81 7.74L13.24 8.03L13.57 8.42L13.78 8.89L13.8 9L11.28 11.71L11.16 11.91L11.08 12.14L10.85 13.97L10.87 14.19L10.93 14.41L11.09 14.71L11.25 14.87L11.43 15L11.64 15.09L11.86 15.14L12.08 15.15L12.3 15.11L12.52 15.03L12.71 14.91L12.94 14.66L13.05 14.47L13.14 14.14L13.29 12.91L15.84 10.18L15.98 10L16.08 9.78L16.15 9.44L16.12 8.9L16.01 8.33L15.76 7.64L15.47 7.13L15.23 6.8L14.83 6.37L14.39 6.01L13.75 5.64L13.21 5.43L12.64 5.3L12.06 5.25L11.65 5.27L11.07 5.36L10.52 5.52L9.86 5.85L9.38 6.18L8.96 6.58L8.69 6.9L8.38 7.38L8.09 8.01L8.04 8.23L8.03 8.46L8.07 8.68L8.15 8.89L8.27 9.08L8.43 9.24L8.61 9.37L8.82 9.47L9.04 9.52L9.26 9.52L9.59 9.45L9.79 9.35L9.97 9.21L10.18 8.94L10.37 8.53ZM21.57 9.1L21.24 8.17L20.82 7.29L20.31 6.44L19.73 5.66L19.07 4.93L18.34 4.27L17.56 3.69L16.71 3.18L15.83 2.76L14.9 2.43L13.95 2.19L12.98 2.05L12 2L11.02 2.05L10.05 2.19L9.1 2.43L8.17 2.76L7.29 3.18L6.44 3.69L5.66 4.27L4.93 4.93L4.27 5.66L3.69 6.44L3.18 7.29L2.76 8.17L2.43 9.1L2.19 10.05L2.05 11.02L2 12L2.05 12.98L2.19 13.95L2.43 14.9L2.76 15.83L3.18 16.71L3.69 17.56L4.27 18.34L4.93 19.07L5.66 19.73L6.44 20.31L7.29 20.82L8.17 21.24L9.1 21.57L10.05 21.81L11.02 21.95L12 22L12.98 21.95L13.95 21.81L14.9 21.57L15.83 21.24L16.71 20.82L17.56 20.31L18.34 19.73L19.07 19.07L19.73 18.34L20.31 17.56L20.82 16.71L21.24 15.83L21.57 14.9L21.81 13.95L21.95 12.98L22 12L21.95 11.02L21.81 10.05ZM19.66 14.32L19.39 15.06L19.06 15.77L18.65 16.44L18.18 17.08L17.66 17.66L17.08 18.18L16.44 18.65L15.77 19.06L15.06 19.39L14.32 19.66L13.56 19.85L12.78 19.96L12 20L11.22 19.96L10.44 19.85L9.68 19.66L8.94 19.39L8.23 19.06L7.56 18.65L6.92 18.18L6.34 17.66L5.82 17.08L5.35 16.44L4.94 15.77L4.61 15.06L4.34 14.32L4.15 13.56L4.04 12.78L4 12L4.04 11.22L4.15 10.44L4.34 9.68L4.61 8.94L4.94 8.23L5.35 7.56L5.82 6.92L6.34 6.34L6.92 5.82L7.56 5.35L8.23 4.94L8.94 4.61L9.68 4.34L10.44 4.15L11.22 4.04L12 4L12.78 4.04L13.56 4.15L14.32 4.34L15.06 4.61L15.77 4.94L16.44 5.35L17.08 5.82L17.66 6.34L18.18 6.92L18.65 7.56L19.06 8.23L19.39 8.94L19.66 9.68L19.85 10.44L19.96 11.22L20 12L19.96 12.78L19.85 13.56ZM13.28 16.98L13.09 16.61L12.79 16.31L12.61 16.2L12.42 16.12L12 16.05L11.58 16.12L11.21 16.31L10.91 16.61L10.8 16.79L10.67 17.19L10.67 17.61L10.72 17.82L10.91 18.19L11.21 18.49L11.39 18.6L11.58 18.68L12 18.75L12.42 18.68L12.61 18.6L12.95 18.35L13.2 18.01L13.33 17.61L13.33 17.19Z"/>
+</svg>
diff --git a/assets/icons/procraft/tabprefs.svg b/assets/icons/procraft/tabprefs.svg
new file mode 100644
index 0000000..2a521e7
--- /dev/null
+++ b/assets/icons/procraft/tabprefs.svg
@@ -0,0 +1,4 @@
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
+ <!-- ProCraft tabprefs icon: original, drawn by tools/icons/draw_icons.py. MIT OR Apache-2.0. -->
+ <path fill="currentColor" fill-rule="evenodd" d="M17.51 17.1L18.01 16.98L18.49 16.8L18.95 16.59L19.39 16.32L19.8 16.02L20.18 15.68L20.52 15.3L20.82 14.89L21.09 14.45L21.3 13.99L21.48 13.51L21.6 13.01L21.67 12.51L21.7 12L21.67 11.49L21.6 10.99L21.48 10.49L21.3 10.01L21.09 9.55L20.82 9.11L20.52 8.7L20.18 8.32L19.8 7.98L19.39 7.68L18.95 7.41L18.49 7.2L18.01 7.02L17.51 6.9L17.01 6.83L16.5 6.8L7.5 6.8L6.99 6.83L6.49 6.9L5.99 7.02L5.51 7.2L5.05 7.41L4.61 7.68L4.2 7.98L3.82 8.32L3.48 8.7L3.18 9.11L2.91 9.55L2.7 10.01L2.52 10.49L2.4 10.99L2.33 11.49L2.3 12L2.33 12.51L2.4 13.01L2.52 13.51L2.7 13.99L2.91 14.45L3.18 14.89L3.48 15.3L3.82 15.68L4.2 16.02L4.61 16.32L5.05 16.59L5.51 16.8L5.99 16.98L6.49 17.1L6.99 17.17L7.5 17.2L16.5 17.2L17.01 17.17ZM7.19 15.18L6.57 15.06L5.99 14.82L5.72 14.66L5.24 14.26L4.84 13.78L4.54 13.22L4.36 12.62L4.32 12.31L4.3 12L4.36 11.38L4.54 10.78L4.84 10.22L5.24 9.74L5.72 9.34L6.28 9.04L6.57 8.94L7.19 8.82L7.5 8.8L16.5 8.8L17.12 8.86L17.72 9.04L18.28 9.34L18.53 9.53L18.97 9.97L19.16 10.22L19.32 10.49L19.56 11.07L19.68 11.69L19.68 12.31L19.56 12.93L19.32 13.51L18.97 14.03L18.53 14.47L18.01 14.82L17.43 15.06L16.81 15.18L16.5 15.2ZM18.89 11.76L18.8 11.3L18.62 10.87L18.36 10.48L18.02 10.14L17.63 9.88L17.2 9.7L16.74 9.61L16.26 9.61L15.8 9.7L15.37 9.88L14.98 10.14L14.64 10.48L14.38 10.87L14.2 11.3L14.11 11.76L14.11 12.24L14.2 12.7L14.38 13.13L14.64 13.52L14.98 13.86L15.37 14.12L15.8 14.3L16.26 14.39L16.74 14.39L17.2 14.3L17.63 14.12L18.02 13.86L18.36 13.52L18.62 13.13L18.8 12.7L18.89 12.24Z"/>
+</svg>
diff --git a/assets/icons/procraft/tabshare.svg b/assets/icons/procraft/tabshare.svg
new file mode 100644
index 0000000..8af8c4a
--- /dev/null
+++ b/assets/icons/procraft/tabshare.svg
@@ -0,0 +1,4 @@
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
+ <!-- ProCraft tabshare icon: original, drawn by tools/icons/draw_icons.py. MIT OR Apache-2.0. -->
+ <path fill="currentColor" fill-rule="evenodd" d="M12.23 2.65L12 2.58L11.84 2.61L11.71 2.7L7.65 6.92L7.57 7.05L7.54 7.21L7.61 7.42L7.72 7.53L7.86 7.59L10.8 7.6L10.81 15.12L10.85 15.35L10.94 15.57L11.07 15.76L11.24 15.93L11.43 16.06L11.65 16.15L12 16.2L12.23 16.18L12.46 16.11L12.67 16L12.85 15.85L13 15.67L13.11 15.46L13.19 15.12L13.2 7.6L16.14 7.59L16.34 7.48L16.43 7.36L16.46 7.21L16.43 7.05L16.35 6.92ZM2.82 20.23L2.89 20.46L3 20.67L3.24 20.93L3.54 21.11L3.88 21.19L20 21.2L20.23 21.18L20.46 21.11L20.76 20.93L21 20.67L21.15 20.35L21.19 20.12L21.2 12.5L21.18 12.27L21.11 12.04L20.93 11.74L20.67 11.5L20.35 11.35L20.12 11.31L19.88 11.31L19.54 11.39L19.24 11.57L19 11.83L18.85 12.15L18.8 12.5L18.8 18.8L5.2 18.8L5.2 12.5L5.18 12.27L5.11 12.04L4.93 11.74L4.76 11.57L4.57 11.44L4.35 11.35L4.12 11.31L3.88 11.31L3.54 11.39L3.24 11.57L3.07 11.74L2.89 12.04L2.81 12.38L2.8 20Z"/>
+</svg>
diff --git a/assets/icons/procraft/tabvideo.svg b/assets/icons/procraft/tabvideo.svg
new file mode 100644
index 0000000..c071364
--- /dev/null
+++ b/assets/icons/procraft/tabvideo.svg
@@ -0,0 +1,4 @@
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
+ <!-- ProCraft tabvideo icon: original, drawn by tools/icons/draw_icons.py. MIT OR Apache-2.0. -->
+ <path fill="currentColor" fill-rule="evenodd" d="M15.46 8.11L15.35 7.73L15.16 7.39L14.91 7.09L14.61 6.84L14.27 6.65L13.89 6.54L13.5 6.5L4.5 6.5L4.11 6.54L3.73 6.65L3.39 6.84L3.09 7.09L2.84 7.39L2.65 7.73L2.54 8.11L2.5 8.5L2.5 15.5L2.54 15.89L2.65 16.27L2.84 16.61L3.09 16.91L3.39 17.16L3.73 17.35L4.11 17.46L4.5 17.5L13.5 17.5L13.89 17.46L14.27 17.35L14.61 17.16L14.91 16.91L15.16 16.61L15.35 16.27L15.46 15.89L15.5 15.5L15.5 8.5ZM17.29 11.62L17.18 11.82L17.16 11.94L17.18 12.18L17.29 12.38L20.52 15.01L20.74 15.12L20.98 15.14L21.21 15.06L21.39 14.89L21.45 14.78L21.5 14.54L21.5 9.46L21.45 9.22L21.31 9.02L21.1 8.89L20.98 8.86L20.74 8.88L20.63 8.92Z"/>
+</svg>
diff --git a/tools/icons/draw_icons.py b/tools/icons/draw_icons.py
index 3b10f85..774d3f5 100644
--- a/tools/icons/draw_icons.py
+++ b/tools/icons/draw_icons.py
@@ -142,10 +142,61 @@ def turning_arrow(mirror):
return shape
+def ring(cx, cy, r, w):
+ """A circle's outline, w thick."""
+ return Point(cx, cy).buffer(r + w / 2, quad_segs=16).difference(Point(cx, cy).buffer(r - w / 2, quad_segs=16))
+
+
+def frame(x0, y0, x1, y1, w, r):
+ """A rounded rectangle's outline, w thick, its outer corners rounded by r."""
+ outer = soft(box(x0, y0, x1, y1), r)
+ return outer.difference(soft(box(x0 + w, y0 + w, x1 - w, y1 - w), max(0.2, r - w)))
+
+
+def plus():
+ """Add: a plus."""
+ return unary_union([capsule((12, 4), (12, 20), 1.3), capsule((4, 12), (20, 12), 1.3)])
+
+
+def canvas_tab():
+ """Canvas: a canvas's frame with a stroke across it."""
+ return unary_union([frame(3, 4, 21, 20, 2.2, 2.0), capsule((7.5, 15.5), (16.5, 8.5), 1.3)])
+
+
+def share_tab():
+ """Share: a tray with an arrow rising out of it."""
+ tray = LineString([(4, 12.5), (4, 20), (20, 20), (20, 12.5)]).buffer(1.2, join_style='round')
+ shaft = capsule((12, 4.5), (12, 15), 1.2)
+ head = soft(Polygon([(12, 2.4), (17, 7.6), (7, 7.6)]), 0.4)
+ return unary_union([tray, shaft, head])
+
+
+def video_tab():
+ """Video: a camera, its body and its lens."""
+ body = soft(box(2.5, 6.5, 15.5, 17.5), 2.0)
+ lens = soft(Polygon([(16.8, 12), (21.5, 8.2), (21.5, 15.8)]), 0.6)
+ return unary_union([body, lens])
+
+
+def prefs_tab():
+ """Preferences: a switch, turned on."""
+ track = capsule((7.5, 12), (16.5, 12), 5.2).difference(capsule((7.5, 12), (16.5, 12), 3.2))
+ return unary_union([track, Point(16.5, 12).buffer(2.4, quad_segs=16)])
+
+
+def help_tab():
+ """Help: a question mark in a ring."""
+ hook = LineString([(12 + 3.0 * math.cos(math.radians(a)), 9.4 + 3.0 * math.sin(math.radians(a)))
+ for a in range(200, 361, 8)] + [(15.0, 9.4), (12.2, 12.4), (12.0, 14.0)])
+ return unary_union([ring(12, 12, 9.0, 2.0), hook.buffer(1.15, join_style='round'), Point(12, 17.4).buffer(1.35, quad_segs=10)])
+
+
DRAWINGS = {
'actions': wrench, 'adjustments': wand, 'selection': selection, 'transform': arrow,
'brush': paintbrush, 'smudge': fingertip, 'erase': eraser, 'layers': layers,
'undo': lambda: turning_arrow(False), 'redo': lambda: turning_arrow(True),
+ 'tabadd': plus, 'tabcanvas': canvas_tab, 'tabshare': share_tab, 'tabvideo': video_tab,
+ 'tabprefs': prefs_tab, 'tabhelp': help_tab,
}