-
Notifications
You must be signed in to change notification settings - Fork 377
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix: Material icon is shown instead of Cupertino icon if its name is …
…the same (#2581) * Fixed: Material icon is shown instead of Cupertino icon if its name is the same Fix #2580 * ci/generate_material_icons_*.sh added
- Loading branch information
1 parent
a695855
commit f7db010
Showing
8 changed files
with
2,858 additions
and
2,697 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
url='https://raw.githubusercontent.com/flutter/flutter/stable/packages/flutter/lib/src/cupertino/icons.dart' | ||
output_file="cupertino_icons.txt" | ||
|
||
echo "Map<String, IconData> cupertinoIcons = {" > "$output_file" | ||
|
||
curl -s $url | python -c ' | ||
import re | ||
for line in __import__("sys").stdin: | ||
match = re.search(r"const IconData ([a-z0-9_]+)", line) | ||
if match: | ||
print("\"cupertino_{}\": CupertinoIcons.{}, ".format(match.group(1), match.group(1))) | ||
' >> "$output_file" | ||
|
||
echo "};" >> "$output_file" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
url='https://raw.githubusercontent.com/flutter/flutter/stable/packages/flutter/lib/src/cupertino/icons.dart' | ||
output_file="cupertino_icons_python.txt" | ||
|
||
curl -s $url | python -c ' | ||
import re | ||
for line in __import__("sys").stdin: | ||
match = re.search(r"const IconData ([a-z0-9_]+)", line) | ||
if match: | ||
print("{} = \"cupertino_{}\"".format(match.group(1).upper(), match.group(1))) | ||
' >> "$output_file" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
url='https://raw.githubusercontent.com/flutter/flutter/stable/packages/flutter/lib/src/material/icons.dart' | ||
output_file="material-icons.txt" | ||
|
||
echo "Map<String, IconData> materialIcons = {" > "$output_file" | ||
|
||
curl -s $url | python -c ' | ||
import re | ||
for line in __import__("sys").stdin: | ||
match = re.search(r"const IconData ([a-z0-9_]+)", line) | ||
if match: | ||
print("\"{}\": Icons.{}, ".format(match.group(1), match.group(1))) | ||
' >> "$output_file" | ||
|
||
echo "};" >> "$output_file" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
url='https://raw.githubusercontent.com/flutter/flutter/master/packages/flutter/lib/src/material/icons.dart' | ||
output_file="material_icons_python.txt" | ||
|
||
curl -s $url | python -c ' | ||
import re | ||
for line in __import__("sys").stdin: | ||
match = re.search(r"const IconData ([a-z0-9_]+)", line) | ||
if match: | ||
print("{} = \"{}\"".format(match.group(1).upper(), match.group(1))) | ||
' >> "$output_file" |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.