From 939629f42b164a9e77fd95ec64caebdb159492ae Mon Sep 17 00:00:00 2001 From: Erick Date: Thu, 11 Jan 2024 23:06:59 -0300 Subject: [PATCH] feat: adding operational system icons --- CHANGELOG.md | 3 +++ example/lib/gallery/sections/icons.dart | 12 ++++++++++++ lib/src/widgets/nes_icon.dart | 21 +++++++++++++++++++++ 3 files changed, 36 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 004e8b4..6011ac6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,9 @@ - feat: add `NesRunningTextLines`. - feat: add `NesPulser`. - feat: allow duration to be configured on selection list. + - feat: add `NesIcons.penguin`. + - feat: add `NesIcons.apple`. + - feat: add `NesIcons.windows`. # 0.12.1 - fix: theme lerp causing error on null access. diff --git a/example/lib/gallery/sections/icons.dart b/example/lib/gallery/sections/icons.dart index 07f7bf8..53da2df 100644 --- a/example/lib/gallery/sections/icons.dart +++ b/example/lib/gallery/sections/icons.dart @@ -353,6 +353,18 @@ class IconsSection extends StatelessWidget { data: NesIcons.rotate, label: 'rotate', ), + _IconEntry( + data: NesIcons.penguin, + label: 'penguin', + ), + _IconEntry( + data: NesIcons.apple, + label: 'apple', + ), + _IconEntry( + data: NesIcons.windows, + label: 'windows', + ), ], ), ], diff --git a/lib/src/widgets/nes_icon.dart b/lib/src/widgets/nes_icon.dart index c600b84..a4b00cc 100644 --- a/lib/src/widgets/nes_icon.dart +++ b/lib/src/widgets/nes_icon.dart @@ -631,6 +631,27 @@ class NesIconCollection { '8,8;2,-1;5,0;2,-1;2,0;5,-1;2,0;6,-1;3,0;2,-1;1,0;2,-1;7,0;2,-1;7,0;3,-1;4,0;6,-1;1,0;2,-1', ), ); + + /// Penguin + late final penguin = NesIconData( + MiniSprite.fromDataString( + '8,8;2,-1;4,0;3,-1;1,0;1,1;2,0;1,1;1,0;2,-1;2,0;2,1;2,0;1,-1;11,0;2,1;5,0;4,1;4,0;4,1;2,0;1,-1;6,0;1,-1', + ), + ); + + /// Apple + late final apple = NesIconData( + MiniSprite.fromDataString( + '8,8;5,-1;1,0;6,-1;1,0;4,-1;6,0;1,-1;3,0;1,1;6,0;1,1;13,0;1,-1;6,0;3,-1;4,0;2,-1', + ), + ); + + /// Windows + late final windows = NesIconData( + MiniSprite.fromDataString( + '8,8;4,0;4,-1;1,0;2,1;4,0;1,-1;1,0;2,1;1,0;2,1;1,0;1,-1;4,0;2,1;1,0;1,-1;1,0;2,1;4,0;1,-1;1,0;2,1;1,0;2,1;1,0;1,-1;4,0;2,1;1,0;4,-1;4,0;1,-1', + ), + ); } /// {@template nes_icon}