mirror of
https://github.com/RGBCube/serenity
synced 2025-05-15 07:24:58 +00:00
LibGUI: Update ShellSyntaxHighlighter to also highlight brace expansions
This commit is contained in:
parent
5640e1bc3a
commit
107a083b5a
1 changed files with 13 additions and 0 deletions
|
@ -140,6 +140,10 @@ private:
|
|||
span.color = m_palette.syntax_punctuation();
|
||||
span.font = &Gfx::Font::default_bold_fixed_width_font();
|
||||
}
|
||||
virtual void visit(const AST::BraceExpansion* node) override
|
||||
{
|
||||
NodeVisitor::visit(node);
|
||||
}
|
||||
virtual void visit(const AST::BarewordLiteral* node) override
|
||||
{
|
||||
NodeVisitor::visit(node);
|
||||
|
@ -350,6 +354,15 @@ private:
|
|||
{
|
||||
NodeVisitor::visit(node);
|
||||
}
|
||||
virtual void visit(const AST::Range* node) override
|
||||
{
|
||||
NodeVisitor::visit(node);
|
||||
|
||||
auto& span = span_for_node(node->start());
|
||||
span.range.set_start(span.range.end());
|
||||
set_offset_range_end(span.range, node->start()->position().end_line, 2);
|
||||
span.color = m_palette.syntax_punctuation();
|
||||
}
|
||||
virtual void visit(const AST::ReadRedirection* node) override
|
||||
{
|
||||
NodeVisitor::visit(node);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue