- CMake
3.24+ - C++20 compiler
- Qt
6.7+ - Qt modules:
Core,Gui,Qml,Quick
cmake -S . -B build
cmake --build buildUseful targets:
ScintillaQuick
If BUILD_TESTING is enabled, test executables are built as well.
Examples and benchmarks are opt-in:
cmake -S . -B build -DSCINTILLAQUICK_BUILD_EXAMPLES=ON -DSCINTILLAQUICK_BUILD_BENCHMARKS=ON
cmake --build buildAfter building with SCINTILLAQUICK_BUILD_EXAMPLES=ON, run:
./build/scintillaquick_minimal_editorOn Windows with a multi-config generator, use the matching configuration path, for example:
./build/Debug/scintillaquick_minimal_editor.exeInstall the package:
cmake --install build --prefix <install-prefix>Then consume it from another CMake project:
find_package(ScintillaQuick CONFIG REQUIRED)
target_link_libraries(my_app PRIVATE ScintillaQuick::ScintillaQuick)The installed package includes Scintilla's public headers. Scintilla internal implementation headers are not part of the installed interface.
Typical C++ integration looks like this:
- Create a
QGuiApplication. - Create a
QQuickWindowor parentQQuickItem. - Instantiate
ScintillaQuick_item. - Attach it to the Qt Quick scene.
- Set geometry, font, and initial text.
The first-party examples and tests use the shared helper in
examples/common/scintillaquick_font.hto select a bundled fixed-font family. By default it picksCascadia Code, andSCINTILLAQUICK_FIXED_FONT_FAMILYcan switch it toCousine. - Drive editor behavior with Scintilla messages through
send().
The editor also has a built-in bottom find/replace panel. Ctrl+F shows the
find row and Ctrl+H adds the replace row. Applications may invoke
showFind(), showFindReplace(), and hideFindPanel() directly, bind to the
findPanelVisible and findReplaceMode properties, and customize the panel
with the findPanelFont and findPanel*Color properties. Set findOptions to
a combination of Scintilla SCFIND_* flags when case-sensitive, whole-word,
or regular-expression matching is required.
See examples/minimal_editor/main.cpp
for a complete runnable example.
Run the registered test suite with:
ctest --test-dir build --output-on-failureRegistered tests currently include smoke, frame-validation, and
visual-regression coverage. Benchmark-backed coverage is registered when
SCINTILLAQUICK_BUILD_BENCHMARKS=ON.
On Windows, visual tests require a desktop session because they create and show
a QQuickWindow.