Skip to content

Fix #15136 (gui: rewrite the online help) - #8959

Merged
danmar merged 1 commit into
cppcheck-opensource:mainfrom
cppchecksolutions:fix-15136
Oct 25, 2026
Merged

danmar merged 1 commit into
cppcheck-opensource:mainfrom
cppchecksolutions:fix-15136

Conversation

@danmar

@danmar danmar commented Oct 25, 2026

Copy link
Copy Markdown
Collaborator

Extend the GUI help with detailed explanations and new screenshots:

  • rewrite the existing pages and describe every option in the project file dialog and the preferences
  • add pages for the main window, suppressions, results files/printing/ statistics, scratchpad/library editor, command line options and troubleshooting
  • add a shared stylesheet, a contents tree and index keywords
  • replace the old screenshots with new ones of the current GUI
  • remove the obsolete manual.html (Cppcheck 1.46)

Extend the GUI help with detailed explanations and new screenshots:
- rewrite the existing pages and describe every option in the project
  file dialog and the preferences
- add pages for the main window, suppressions, results files/printing/
  statistics, scratchpad/library editor, command line options and
  troubleshooting
- add a shared stylesheet, a contents tree and index keywords
- replace the old screenshots with new ones of the current GUI
- remove the obsolete manual.html (Cppcheck 1.46)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@danmar danmar changed the title gui: rewrite the online help Fix #15136 (gui: rewrite the online help) Oct 25, 2026
@danmar danmar added the ai-assisted contains code which was written with the assistance of AI - please review extra carefully label Oct 25, 2026

@dmcppcheck dmcppcheck left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AI review

This PR only changes documentation. I found one factual error, in tools.html: it says scratchpad code "can not include your own headers". That is wrong. The scratchpad analyzes the code with the include paths of the open project, so #include "myheader.h" works for headers in those folders.

Nothing else I checked was wrong:

  • Every link, anchor and image in the HTML pages and in online-help.qhp resolves.
  • online-help.qhp lists every file in gui/help, and nothing still refers to the deleted manual.html or the old screenshots.
  • These parts match the GUI source:
    • the command line options;
    • the startup behaviour;
    • the keyboard shortcuts and menu names;
    • the default build dir name;
    • which fields are disabled after an import;
    • the import file types;
    • the default file name in the scratchpad;
    • the message about addons needing a build directory.

Testing

  • Build and tests: I did not build cppcheck or testrunner, and I ran no tests. The PR touches only gui/help (HTML, CSS, PNG and the .qhp file), so no C++ code or test changes. The GUI and qhelpgenerator are not available here, so I could not generate the help collection or view it.

  • Links and files: I wrote a small Python checker (scratch/chk.py, run with python3 -I chk.py /work/pr/gui/help). For every href and src in the help pages and every ref in online-help.qhp, it checks that the target file and the <a name=...> anchor exist. It also checks that every HTML, PNG and CSS file is listed in <files> and that every listed file exists. It printed no problems. The "Previous" / "Next" links form one consistent chain.

  • Text against the source: I compared what the help says with the GUI code. Sources checked:

    • gui/main.cpp and MainWindow::handleCLIParams (-p, -l, -d, .cppcheck and .xml arguments);
    • MainWindow::loadSettings (reopening the last project only when there are no arguments);
    • the shortcuts and menu texts in mainwindow.ui;
    • the build dir name at mainwindow.cpp:2069;
    • ProjectFileDialog::updatePathsAndDefines and the import filters;
    • ResultsTree::keyPressEvent (Enter opens the editor);
    • ScratchPad::checkButtonClicked (empty name means test.cpp).

    Everything matched except the scratchpad remark about headers. MainWindow::analyzeCode calls getCppcheckSettings, which adds the project's include folders to the settings (addIncludeDirs at mainwindow.cpp:1140), and then calls checkBuffer with those settings, so headers in the project's include folders are found.


Automated review of 715fe3c by Claude. The pull request was built and tested locally.

Comment thread gui/help/tools.html
@danmar
danmar merged commit 169f6ae into cppcheck-opensource:main Oct 25, 2026
71 checks passed
@danmar
danmar deleted the fix-15136 branch October 25, 2026 13:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ai-assisted contains code which was written with the assistance of AI - please review extra carefully

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants