mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-10-30 12:47:13 -06:00
.ai palette: color groups are capped as swatches are
This commit is contained in:
@@ -118,7 +118,10 @@ pub(super) fn palette(data: &[u8]) -> Palette {
|
||||
});
|
||||
}
|
||||
"Pg" => {
|
||||
if let Some(name) = first_text(&vals) {
|
||||
// Capped as swatches are: a file of many `Pg` would make as many empty groups.
|
||||
if let Some(name) = first_text(&vals)
|
||||
&& out.groups.len() < MAX_SWATCHES
|
||||
{
|
||||
out.groups.push((name, Vec::new()));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user