Skip to content

Commit

Permalink
changed start symbol color
Browse files Browse the repository at this point in the history
  • Loading branch information
maveme committed Sep 14, 2020
1 parent 0e8ac49 commit 09e59f6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/kogi/Production2Block.rsc
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Block production2Block(prod(\start(sort(str name)), _, _), map[str, bool] multip
//initialBlock = name;

kogi::Block::Message message = Message::message( "%1", [ arg("start", kogi::Block::\value(check = [name])) ] );
return block("start", name, [message], colour = hsv(90));
return block("start", name, [message], colour = hsv(120));
}
// FIX: The java grammar returns this as empty
map[str, bool] getSymbolsMultiplicity(list[Symbol] symbols, map[str, bool] multiplicity)
Expand All @@ -27,7 +27,7 @@ map[str, bool] getSymbolsMultiplicity(list[Symbol] symbols, map[str, bool] multi
Block production2Block(prod(symbol:sort(str name), list[Symbol] symbols, set[Attr] attributes), map[str, bool] multiplicity, str startProduction, str labelName = "") {
kogi::Block::Message message = symbols2Message(ignoreLayoutSymbols(symbols), getSymbolsMultiplicity(symbols, multiplicity), lexicalName = name);
if(startProduction == name)
return block(setBlockName(labelName, name), setBlockType(name, labelName), [message], colour = hsv(90));
return block(setBlockName(labelName, name), setBlockType(name, labelName), [message], colour = hsv(120));
else if (name in multiplicity && !multiplicity[name])
return block(setBlockName(labelName, name), setBlockType(name, labelName), [message], output = Ref::block(name), inputsInline = true, colour = hsv(arbInt(360)), tooltip = labelName);
else
Expand Down

0 comments on commit 09e59f6

Please sign in to comment.