mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 06:09:50 -06:00
Qt/GameConfigWidget: Complete overhaul
This commit is contained in:
28
Source/Core/DolphinQt/Config/GameConfigHighlighter.h
Normal file
28
Source/Core/DolphinQt/Config/GameConfigHighlighter.h
Normal file
@ -0,0 +1,28 @@
|
||||
// Copyright 2018 Dolphin Emulator Project
|
||||
// Licensed under GPLv2+
|
||||
// Refer to the license.txt file included.
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <vector>
|
||||
|
||||
#include <QRegularExpression>
|
||||
#include <QSyntaxHighlighter>
|
||||
#include <QTextCharFormat>
|
||||
|
||||
struct HighlightingRule;
|
||||
|
||||
class GameConfigHighlighter : public QSyntaxHighlighter
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit GameConfigHighlighter(QTextDocument* parent = nullptr);
|
||||
~GameConfigHighlighter();
|
||||
|
||||
protected:
|
||||
void highlightBlock(const QString& text) override;
|
||||
|
||||
private:
|
||||
std::vector<HighlightingRule> m_rules;
|
||||
};
|
Reference in New Issue
Block a user