Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(232)

Unified Diff: ui/gfx/vector_icon_types.h

Issue 1270783005: V1 of material design find in page bar (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: suffixual f Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/gfx/paint_vector_icon.cc ('k') | ui/gfx/vector_icons/aggregate_vector_icons.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gfx/vector_icon_types.h
diff --git a/ui/gfx/vector_icon_types.h b/ui/gfx/vector_icon_types.h
index e31a72d6be16afd590d6f227a44f146e8ef59cfb..096f1404e11695ddc4965b3ef9ef6d9ae36e8d86 100644
--- a/ui/gfx/vector_icon_types.h
+++ b/ui/gfx/vector_icon_types.h
@@ -24,6 +24,9 @@ enum CommandType {
NEW_PATH,
// Sets the color for the current path.
PATH_COLOR_ARGB,
+ // By default, the path will be filled. This changes the paint action to
+ // stroke at the given width.
+ STROKE,
// These correspond to pathing commands.
MOVE_TO,
R_MOVE_TO,
@@ -39,6 +42,9 @@ enum CommandType {
CLOSE,
// Sets the dimensions of the canvas in dip. (Default is kReferenceSizeDip.)
CANVAS_DIMENSIONS,
+ // Sets a bounding rect for the path. This allows fine adjustment because it
+ // can tweak edge anti-aliasing. Args are x, y, w, h.
+ CLIP,
// Marks the end of the list of commands.
END
};
@@ -56,6 +62,10 @@ struct PathElement {
// Returns an array of path commands and arguments, terminated by END.
const PathElement* GetPathForVectorIcon(VectorIconId id);
+// As above, but returns an icon specifically adjusted for 1x scale factors.
+// This draws from icon files that end with .1x.icon. If no such file exists,
+// it will fall back to GetPathForVectorIcon.
+const PathElement* GetPathForVectorIconAt1xScale(VectorIconId id);
} // namespace gfx
« no previous file with comments | « ui/gfx/paint_vector_icon.cc ('k') | ui/gfx/vector_icons/aggregate_vector_icons.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698