From 8f728cb4b649178d3a858f569c1364a1e181996c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oliver=20St=C3=B6neberg?= Date: Fri, 15 Apr 2022 16:17:36 +0200 Subject: [PATCH] added (partial) support for specifying C++23 and support more "-std" options (#3212) --- Makefile | 2 +- cli/cmdlineparser.cpp | 29 +- gui/checkthread.cpp | 20 +- gui/cppcheck_de.ts | 455 ++++++++++++-------- gui/cppcheck_es.ts | 651 ++++++++++++++++++++--------- gui/cppcheck_fi.ts | 420 ++++++++++--------- gui/cppcheck_fr.ts | 555 ++++++++++++++++--------- gui/cppcheck_it.ts | 631 +++++++++++++++++++--------- gui/cppcheck_ja.ts | 824 ++++++++++++++++++++++++++++--------- gui/cppcheck_ko.ts | 630 +++++++++++++++++++--------- gui/cppcheck_nl.ts | 621 +++++++++++++++++++--------- gui/cppcheck_ru.ts | 743 +++++++++++++++++++++++++-------- gui/cppcheck_sr.ts | 447 +++++++++++--------- gui/cppcheck_sv.ts | 784 ++++++++++++++++++++++++++--------- gui/cppcheck_zh_CN.ts | 726 ++++++++++++++++++++++++-------- gui/mainwindow.cpp | 4 + gui/mainwindow.ui | 12 + lib/checkother.cpp | 4 +- lib/importproject.cpp | 40 +- lib/path.cpp | 11 +- lib/pathmatch.cpp | 4 +- lib/preprocessor.cpp | 3 + lib/standards.h | 74 ++-- lib/utils.cpp | 11 + lib/utils.h | 2 + test/testcmdlineparser.cpp | 17 + test/testpreprocessor.cpp | 11 +- 27 files changed, 5412 insertions(+), 2319 deletions(-) diff --git a/Makefile b/Makefile index cac885edc..00cb1352c 100644 --- a/Makefile +++ b/Makefile @@ -495,7 +495,7 @@ $(libcppdir)/errortypes.o: lib/errortypes.cpp lib/config.h lib/errortypes.h $(libcppdir)/forwardanalyzer.o: lib/forwardanalyzer.cpp lib/analyzer.h lib/astutils.h lib/config.h lib/errortypes.h lib/forwardanalyzer.h lib/importproject.h lib/library.h lib/mathlib.h lib/platform.h lib/settings.h lib/standards.h lib/suppressions.h lib/symboldatabase.h lib/templatesimplifier.h lib/timer.h lib/token.h lib/utils.h lib/valueflow.h lib/valueptr.h $(CXX) ${INCLUDE_FOR_LIB} $(CPPFLAGS) $(CPPFILESDIR) $(CXXFLAGS) $(UNDEF_STRICT_ANSI) -c -o $(libcppdir)/forwardanalyzer.o $(libcppdir)/forwardanalyzer.cpp -$(libcppdir)/importproject.o: lib/importproject.cpp externals/picojson/picojson.h externals/tinyxml2/tinyxml2.h lib/config.h lib/errortypes.h lib/importproject.h lib/library.h lib/mathlib.h lib/path.h lib/platform.h lib/settings.h lib/standards.h lib/suppressions.h lib/templatesimplifier.h lib/timer.h lib/token.h lib/tokenize.h lib/tokenlist.h lib/utils.h lib/valueflow.h +$(libcppdir)/importproject.o: lib/importproject.cpp externals/picojson/picojson.h externals/simplecpp/simplecpp.h externals/tinyxml2/tinyxml2.h lib/config.h lib/errortypes.h lib/importproject.h lib/library.h lib/mathlib.h lib/path.h lib/platform.h lib/settings.h lib/standards.h lib/suppressions.h lib/templatesimplifier.h lib/timer.h lib/token.h lib/tokenize.h lib/tokenlist.h lib/utils.h lib/valueflow.h $(CXX) ${INCLUDE_FOR_LIB} $(CPPFLAGS) $(CPPFILESDIR) $(CXXFLAGS) $(UNDEF_STRICT_ANSI) -c -o $(libcppdir)/importproject.o $(libcppdir)/importproject.cpp $(libcppdir)/infer.o: lib/infer.cpp lib/calculate.h lib/config.h lib/errortypes.h lib/infer.h lib/mathlib.h lib/valueflow.h lib/valueptr.h diff --git a/cli/cmdlineparser.cpp b/cli/cmdlineparser.cpp index 0c3f84320..6a6874ff8 100644 --- a/cli/cmdlineparser.cpp +++ b/cli/cmdlineparser.cpp @@ -768,22 +768,19 @@ bool CmdLineParser::parseFromArgs(int argc, const char* const argv[]) } // --std - else if (std::strcmp(argv[i], "--std=c89") == 0) { - mSettings->standards.c = Standards::C89; - } else if (std::strcmp(argv[i], "--std=c99") == 0) { - mSettings->standards.c = Standards::C99; - } else if (std::strcmp(argv[i], "--std=c11") == 0) { - mSettings->standards.c = Standards::C11; - } else if (std::strcmp(argv[i], "--std=c++03") == 0) { - mSettings->standards.cpp = Standards::CPP03; - } else if (std::strcmp(argv[i], "--std=c++11") == 0) { - mSettings->standards.cpp = Standards::CPP11; - } else if (std::strcmp(argv[i], "--std=c++14") == 0) { - mSettings->standards.cpp = Standards::CPP14; - } else if (std::strcmp(argv[i], "--std=c++17") == 0) { - mSettings->standards.cpp = Standards::CPP17; - } else if (std::strcmp(argv[i], "--std=c++20") == 0) { - mSettings->standards.cpp = Standards::CPP20; + else if (std::strncmp(argv[i], "--std=", 6) == 0) { + const std::string std = argv[i] + 6; + // TODO: print error when standard is unknown + if (std::strncmp(std.c_str(), "c++", 3) == 0) { + mSettings->standards.cpp = Standards::getCPP(std); + } + else if (std::strncmp(std.c_str(), "c", 1) == 0) { + mSettings->standards.c = Standards::getC(std); + } + else { + printError("unknown --std value '" + std + "'"); + return false; + } } else if (std::strncmp(argv[i], "--suppress=", 11) == 0) { diff --git a/gui/checkthread.cpp b/gui/checkthread.cpp index d5d74f100..4d3717cd4 100644 --- a/gui/checkthread.cpp +++ b/gui/checkthread.cpp @@ -201,22 +201,10 @@ void CheckThread::runAddonsAndTools(const ImportProject::FileSettings *fileSetti if (!fileSettings->standard.empty()) args << ("-std=" + QString::fromStdString(fileSettings->standard)); else { - switch (mCppcheck.settings().standards.cpp) { - case Standards::CPP03: - args << "-std=c++03"; - break; - case Standards::CPP11: - args << "-std=c++11"; - break; - case Standards::CPP14: - args << "-std=c++14"; - break; - case Standards::CPP17: - args << "-std=c++17"; - break; - case Standards::CPP20: - args << "-std=c++20"; - break; + // TODO: pass C or C++ standard based on file type + const std::string std = mCppcheck.settings().standards.getCPP(); + if (!std.empty()) { + args << ("-std=" + QString::fromStdString(std)); } } diff --git a/gui/cppcheck_de.ts b/gui/cppcheck_de.ts index 404579f07..1f5e0b16e 100644 --- a/gui/cppcheck_de.ts +++ b/gui/cppcheck_de.ts @@ -41,6 +41,27 @@ der GNU General Public License Version 3 lizenziert <html><head/><body><p>Many thanks to these libraries that we use:</p><ul style="margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; -qt-list-indent: 1;"><li style=" margin-top:12px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">pcre</li><li style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">picojson</li><li style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">qt</li><li style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">tinyxml2</li></ul></body></html> + + <html><head/><body> +<p>Many thanks to these libraries that we use:</p><ul> +<li>pcre</li> +<li>picojson</li> +<li>qt</li> +<li>tinyxml2</li> +<li>z3</li></ul></body></html> + <html><head/><body> +<p>Many thanks to these libraries that we use:</p><ul> +<li>tinyxml2</li> +<li>picojson</li> +<li>pcre</li> +<li>qt</li></ul></body></html> + <html><head/><body> +<p>Vielen Dank für die von uns genutzten Bibliotheken:</p><ul> +<li>tinyxml2</li> +<li>picojson</li> +<li>pcre</li> +<li>qt</li></ul></body></html> + ApplicationDialog @@ -431,24 +452,24 @@ Parameter: -l(line) (file) MainWindow - - - - - - - - - - - - - + + + + + + + + + + + + + Cppcheck Cppcheck - + Standard Standard @@ -478,475 +499,475 @@ Parameter: -l(line) (file) C++-Standard - + &C standard &C-Standard - + &Edit &Bearbeiten - + &License... &Lizenz... - + A&uthors... &Autoren... - + &About... Ü&ber... - + &Files... &Dateien... - - + + Analyze files Analysiere Dateien - + Ctrl+F Strg+F - + &Directory... &Verzeichnis... - - + + Analyze directory Analysiere Verzeichnis - + Ctrl+D Strg+D - + Ctrl+R Strg+R - + &Stop &Stoppen - - + + Stop analysis Analyse abbrechen - + Esc Esc - + &Save results to file... &Ergebnisse in Datei speichern... - + Ctrl+S Strg+S - + &Quit &Beenden - + &Clear results Ergebnisse &löschen - + &Preferences &Einstellungen - - + + Show errors Zeige Fehler - - + + Show warnings Zeige Warnungen - - + + Show performance warnings Zeige Performance-Warnungen - + Show &hidden Zeige &versteckte - - + + Information Information - + Show information messages Zeige Informationsmeldungen - + Show portability warnings Zeige Portabilitätswarnungen - + Show Cppcheck results Zeige Cppcheck-Ergebnisse - + Clang Clang - + Show Clang results Zeige Clang-Ergebnisse - + &Filter &Filter - + Filter results Gefilterte Ergebnisse - + Windows 32-bit ANSI Windows 32-bit, ANSI - + Windows 32-bit Unicode Windows 32-bit, Unicode - + Unix 32-bit Unix 32-bit - + Unix 64-bit Unix 64-bit - + Windows 64-bit Windows 64-bit - + &Print... Drucken... - + Print the Current Report Aktuellen Bericht ausdrucken - + Print Pre&view... Druckvorschau - + Open a Print Preview Dialog for the Current Results Druckvorschaudialog für aktuelle Ergebnisse öffnen - + Open library editor Bibliothekseditor öffnen - + &Check all Alle &auswählen - + Filter Filter - + &Reanalyze modified files Veränderte Dateien neu analysieren - + Reanal&yze all files Alle Dateien erneut anal&ysieren - + Ctrl+Q - + Style war&nings Stilwar&nungen - + E&rrors F&ehler - + &Uncheck all Alle a&bwählen - + Collapse &all Alle &reduzieren - + &Expand all Alle &erweitern - + &Standard &Standard - + Standard items Standardeinträge - + Toolbar Symbolleiste - + &Categories &Kategorien - + Error categories Fehler-Kategorien - + &Open XML... Öffne &XML... - + Open P&roject File... Pr&ojektdatei öffnen... - + Ctrl+Shift+O - + Sh&ow Scratchpad... &Zeige Schmierzettel... - + &New Project File... &Neue Projektdatei... - + Ctrl+Shift+N - + &Log View &Loganzeige - + Log View Loganzeige - + C&lose Project File Projektdatei &schließen - + &Edit Project File... Projektdatei &bearbeiten... - + &Statistics &Statistik - + &Warnings &Warnungen - + Per&formance warnings Per&formance-Warnungen - + &Information &Information - + &Portability &Portabilität - + P&latforms P&lattformen - + C++&11 C++&11 - + C&99 C&99 - + &Posix Posix - + C&11 C&11 - + &C89 &C89 - + &C++03 &C++03 - + &Library Editor... &Bibliothekseditor - + &Auto-detect language Sprache &automatisch erkennen - + &Enforce C++ C++ &erzwingen - + E&nforce C C e&rzwingen - + C++14 C++14 - + Reanalyze and check library Neu analysieren und Bibliothek prüfen - + Check configuration (defines, includes) Prüfe Konfiguration (Definitionen, Includes) - + C++17 C++17 - + C++20 C++20 - + &Contents &Inhalte - + Categories Kategorien - - + + Show style warnings Zeige Stilwarnungen - + Open the help contents Öffnet die Hilfe-Inhalte - + F1 F1 @@ -957,17 +978,17 @@ Parameter: -l(line) (file) - + Quick Filter: Schnellfilter: - + Select configuration Konfiguration wählen - + Found project file: %1 Do you want to load this project file instead? @@ -976,65 +997,65 @@ Do you want to load this project file instead? Möchten Sie stattdessen diese öffnen? - + File not found Datei nicht gefunden - + Bad XML Fehlerhaftes XML - + Missing attribute Fehlendes Attribut - + Bad attribute value Falscher Attributwert - + Duplicate platform type Plattformtyp doppelt - + Platform type redefined Plattformtyp neu definiert - + Failed to load the selected library '%1'. %2 Laden der ausgewählten Bibliothek '%1' schlug fehl. %2 - + License Lizenz - + Authors Autoren - + Save the report file Speichert die Berichtdatei - - + + XML files (*.xml) XML-Dateien (*.xml) - + There was a problem with loading the editor application settings. This is probably because the settings were changed between the Cppcheck versions. Please check (and fix) the editor application settings, otherwise the editor program might not start correctly. @@ -1043,117 +1064,129 @@ This is probably because the settings were changed between the Cppcheck versions Dies wurde vermutlich durch einen Wechsel der Cppcheck-Version hervorgerufen. Bitte prüfen (und korrigieren) Sie die Einstellungen, andernfalls könnte die Editor-Anwendung nicht korrekt starten. - + You must close the project file before selecting new files or directories! Sie müssen die Projektdatei schließen, bevor Sie neue Dateien oder Verzeichnisse auswählen! - + The library '%1' contains unknown elements: %2 Die Bibliothek '%1' enthält unbekannte Elemente: %2 - + Unsupported format Nicht unterstütztes Format - + Unknown element Unbekanntes Element - + Unknown issue Unbekannter Fehler - + Error Fehler - + Failed to load %1. Your Cppcheck installation is broken. You can use --data-dir=<directory> at the command line to specify where this file is located. Please note that --data-dir is supposed to be used by installation scripts and therefore the GUI does not start when it is used, all that happens is that the setting is configured. Laden von %1 fehlgeschlagen. Ihre Cppcheck-Installation ist defekt. Sie können --data-dir=<Verzeichnis> als Kommandozeilenparameter verwenden, um anzugeben, wo die Datei sich befindet. Bitte beachten Sie, dass --data-dir in Installationsroutinen genutzt werden soll, und die GUI bei dessen Nutzung nicht startet, sondern die Einstellungen konfiguriert. - + Current results will be cleared. + +Opening a new XML file will clear current results.Do you want to proceed? + Aktuelle Ergebnisse werden gelöscht. + + Das Einlesen einer XML-Datei löscht die aktuellen Ergebnisse. Fortfahren? + + + Open the report file Berichtdatei öffnen - + Text files (*.txt) Textdateien (*.txt) - + CSV files (*.csv) CSV-Dateien (*.csv) - + Cppcheck - %1 + Cppcheck - %1 + + + Project files (*.cppcheck);;All files(*.*) Projektdateien (*.cppcheck);;Alle Dateien(*.*) - + Select Project File Projektdatei auswählen - - - + + + Project: Projekt: - + No suitable files found to analyze! Keine passenden Dateien für Analyse gefunden! - + C/C++ Source C/C++-Quellcode - + Compile database Compilerdatenbank - + Visual Studio Visual Studio - + Borland C++ Builder 6 Borland C++-Builder 6 - + Select files to analyze Dateien für Analyse auswählen - + Select directory to analyze Verzeichnis für Analyse auswählen - + Select the configuration that will be analyzed Zu analysierende Konfiguration auswählen - + Found project files from the directory. Do you want to proceed analysis without using any of these project files? @@ -1162,7 +1195,7 @@ Do you want to proceed analysis without using any of these project files? - + Current results will be cleared. Opening a new XML file will clear current results. @@ -1173,7 +1206,7 @@ Eine neue XML-Datei zu öffnen wird die aktuellen Ergebnisse löschen Möchten sie fortfahren? - + Analyzer is running. Do you want to stop the analysis and exit Cppcheck? @@ -1182,47 +1215,47 @@ Do you want to stop the analysis and exit Cppcheck? Wollen sie die Analyse abbrechen und Cppcheck beenden? - + About - + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) XML-Dateien (*.xml);;Textdateien (*.txt);;CSV-Dateien (*.csv) - + Build dir '%1' does not exist, create it? Erstellungsverzeichnis '%1' existiert nicht. Erstellen? - + To check the project using addons, you need a build directory. - + Failed to import '%1', analysis is stopped Import von '%1' fehlgeschlagen; Analyse wurde abgebrochen. - + Project files (*.cppcheck) Projektdateien (*.cppcheck) - + Select Project Filename Projektnamen auswählen - + No project file loaded Keine Projektdatei geladen - + The project file %1 @@ -1368,6 +1401,10 @@ Options: Note: Put your own custom .cfg files in the same folder as the project file. You should see them above. Hinweis: Legen Sie eigene .cfg-Dateien in den Ordner der Projektdatei. Dann sollten sie oben sichtbar werden. + + Addons and tools + Addons und Werkzeuge + MISRA C 2012 @@ -1460,6 +1497,10 @@ Options: Down Ab + + Checking + Prüfung + Platform @@ -1486,6 +1527,10 @@ Options: If you want to design your classes to be as flexible and robust as possible then the public interface must be very robust. Cppcheck will asumme that arguments can take *any* value. + + Check code in headers (slower analysis, more results) + Prüfe Code in Headern (langsamere Analyse, mehr Ergebnisse) + Check code in unused templates (should be ON normally, however in theory you can safely ignore warnings in unused templates) @@ -1522,6 +1567,14 @@ Options: Warning tags (separated by semicolon) Warnungs-Tags (Semikolon-getrennt) + + Exclude source files in paths + Quelldateien in Pfaden ausschließen + + + Note: Addons require <a href="https://www.python.org/">Python</a> beeing installed. + Hinweis: Addons setzen voraus, dass <a href="https://www.python.org/">Python</a> installiert ist. + External tools @@ -1552,6 +1605,10 @@ Options: Cppcheck (built in) + + Clang + Clang + Check that each class has a safe public interface @@ -1623,6 +1680,10 @@ Options: Coding standards Programmierstandards + + CERT + CERT + Clang analyzer @@ -1647,81 +1708,99 @@ Options: Projektdatei: %1 - + Select Cppcheck build dir Wähle Cppcheck-Erstellungsverzeichnis - + Select include directory Wähle Include-Verzeichnisse - + Select a directory to check Wähle zu prüfendes Verzeichnis - (no rule texts file) - (keine Regeltexte) + (keine Regeltexte) - + Clang-tidy (not found) Clang-tidy (nicht gefunden) - + Visual Studio Visual Studio - + Compile database Compilerdatenbank - + Borland C++ Builder 6 Borland C++-Builder 6 - + Import Project Projekt importieren - + Select directory to ignore Wähle zu ignorierendes Verzeichnis - + Source files - + All files - + Exclude file - + Select MISRA rule texts file Wähle MISRA-Regeltext-Datei - + MISRA rule texts file (%1) MISRA-Regeltext-Datei + + QDialogButtonBox + + OK + OK + + + Cancel + Abbrechen + + + Close + Schließen + + + Save + Speichern + + QObject @@ -2176,6 +2255,10 @@ Legen Sie unter dem Menü Ansicht fest, welche Arten von Fehlern angezeigt werde Copy complete Log Gesamtes Protokoll kopieren + + No errors found, nothing to save. + Keine Fehler gefunden, nichts zu speichern. + @@ -2197,6 +2280,14 @@ Legen Sie unter dem Menü Ansicht fest, welche Arten von Fehlern angezeigt werde Warning Details Warnungs-Details + + Functions + Funktionen + + + Variables + Variablen + ScratchPad diff --git a/gui/cppcheck_es.ts b/gui/cppcheck_es.ts index 5fee78d88..772efd65a 100644 --- a/gui/cppcheck_es.ts +++ b/gui/cppcheck_es.ts @@ -407,23 +407,50 @@ Parameters: -l(line) (file) Valores válidos + + LogView + + Checking Log + Comprobando el log + + + Clear + Limpiar + + + Save Log + Guardar el log + + + Text files (*.txt *.log);;All files (*.*) + Archivos de texto (*.txt *.log);;Todos los archivos(*.*) + + + Cppcheck + Cppcheck + + + Could not open file for writing: "%1" + No se pudo abrir el fichero para escritura: "%1" + + MainWindow - - - - - - - - - - - - - + + + + + + + + + + + + + Cppcheck Cppcheck @@ -447,233 +474,289 @@ Parameters: -l(line) (file) &Help &Ayuda + + &Check + &Comprobar + C++ standard C++ estándar - + &C standard C standard C estándar - + &Edit &Editar - + Standard Estándar - + Categories Categorías - + &License... &Licencia... - + A&uthors... A&utores... - + &About... &Acerca de... - + &Files... &Ficheros... - - + + Analyze files Check files Comprobar archivos - + Ctrl+F Ctrl+F - + &Directory... &Carpeta... - - + + Analyze directory Check directory Comprobar carpeta - + Ctrl+D Ctrl+D - + &Recheck files + &Volver a revisar ficheros + + + Ctrl+R Ctrl+R - + &Stop &Detener - - + + Stop analysis Stop checking Detener comprobación - + Esc Esc - + &Save results to file... &Guardar los resultados en el fichero... - + Ctrl+S Ctrl+S - + &Quit &Salir - + &Clear results &Limpiar resultados - + &Preferences &Preferencias - - + Style warnings + Advertencias de estilo + + + + Show style warnings Mostrar advertencias de estilo - - + Errors + Errores + + + + Show errors Mostrar errores - - + Show S&cratchpad... + Mostrar S&cratchpad... + + + + Information Información - + Show information messages Mostrar mensajes de información - + Portability + Portabilidad + + + Show portability warnings Mostrar advertencias de portabilidad - + Show Cppcheck results - + Clang - + Show Clang results - + &Filter &Filtro - + Filter results Resultados del filtro - + Windows 32-bit ANSI Windows 32-bit ANSI - + Windows 32-bit Unicode Windows 32-bit Unicode - + Unix 32-bit Unix 32-bit - + Unix 64-bit Unix 64-bit - + Windows 64-bit Windows 64-bit - + Platforms + Plataformas + + + C++11 + C++11 + + + C99 + C99 + + + Posix + Posix + + + C11 + C11 + + + C89 + C89 + + + C++03 + C++03 + + + &Print... Im&primir... - + Print the Current Report Imprimir el informe actual - + Print Pre&view... Pre&visualización de impresión... - + Open a Print Preview Dialog for the Current Results Abre el diálogo de previsualización de impresión para el informe actual - + Library Editor... + Editor de bibliotecas... + + + Open library editor Abrir el editor de bibliotecas - + &Check all &Seleccionar todo @@ -683,345 +766,377 @@ Parameters: -l(line) (file) - + Filter Filtro - + &Reanalyze modified files &Recheck modified files - + Reanal&yze all files - + Ctrl+Q - + Style war&nings - + E&rrors - + &Uncheck all &Deseleccionar todo - + Collapse &all Contraer &todo - + &Expand all &Expandir todo - + &Standard &Estándar - + Standard items Elementos estándar - + &Contents &Contenidos - + Open the help contents Abrir la ayuda de contenidos - + F1 F1 - + Toolbar Barra de herramientas - + &Categories &Categorías - + Error categories Categorías de error - + &Open XML... &Abrir XML... - + Open P&roject File... Abrir P&royecto... - + Ctrl+Shift+O - + Sh&ow Scratchpad... - + &New Project File... &Nuevo Proyecto... - + Ctrl+Shift+N - + &Log View &Visor del log - + Log View Visor del log - + C&lose Project File C&errar Proyecto - + &Edit Project File... &Editar Proyecto... - + &Statistics &Estadísticas - + &Warnings - + Per&formance warnings - + &Information - + &Portability - + P&latforms - + C++&11 - + C&99 - + &Posix - + C&11 - + &C89 - + &C++03 - + &Library Editor... - + &Auto-detect language - + &Enforce C++ - + E&nforce C - + C++14 C++14 - + Reanalyze and check library - + Check configuration (defines, includes) - + C++17 C++17 - + C++20 C++20 - - + Warnings + Advertencias + + + + Show warnings Mostrar advertencias - - + Performance warnings + Advertencias de rendimiento + + + + Show performance warnings Mostrar advertencias de rendimiento - + Show &hidden Mostrar &ocultos - + There was a problem with loading the editor application settings. This is probably because the settings were changed between the Cppcheck versions. Please check (and fix) the editor application settings, otherwise the editor program might not start correctly. - + No suitable files found to check! + ¡No se han encontrado ficheros para comprobar! + + + You must close the project file before selecting new files or directories! ¡Tienes que cerrar el proyecto antes de seleccionar nuevos ficheros o carpetas! - + Select directory to check + Selecciona una carpeta para comprobar + + + Select configuration - + File not found Archivo no encontrado - + Bad XML XML malformado - + Missing attribute Falta el atributo - + Bad attribute value - + Unsupported format Formato no soportado - + Failed to load the selected library '%1'. %2 - - + + XML files (*.xml) Archivos XML (*.xml) - + Open the report file Abrir informe - + Checking is running. + +Do you want to stop the checking and exit Cppcheck? + El proceso de comprobación está en curso. + +¿Quieres parar la comprobación y salir del Cppcheck? + + + License Licencia - + Authors Autores - + XML files version 2 (*.xml);;XML files version 1 (*.xml);;Text files (*.txt);;CSV files (*.csv) + Archivos XML versión 2 (*.xml);;Archivos XML versión 1 (*.xml);;Archivos de texto (*.txt);;Archivos CSV (*.csv) + + + Save the report file Guardar informe - + Quick Filter: Filtro rápido: - + Select files to check + Selecciona los archivos a comprobar + + + Found project file: %1 Do you want to load this project file instead? @@ -1030,119 +1145,147 @@ Do you want to load this project file instead? ¿Quiere cargar este fichero de proyecto en su lugar? - + Found project files from the directory. + +Do you want to proceed checking without using any of these project files? + Se encontraron ficheros de proyecto en el directorio. + +¿Quiere proceder a comprobar sin utilizar ninguno de estos ficheros de proyecto? + + + The library '%1' contains unknown elements: %2 La biblioteca '%1' contiene elementos deconocidos: %2 - + Duplicate platform type - + Platform type redefined - + Unknown element - + Unknown issue - + Error Error - + Failed to load %1. Your Cppcheck installation is broken. You can use --data-dir=<directory> at the command line to specify where this file is located. Please note that --data-dir is supposed to be used by installation scripts and therefore the GUI does not start when it is used, all that happens is that the setting is configured. - + Current results will be cleared. + +Opening a new XML file will clear current results.Do you want to proceed? + Los resultados actuales serán eliminados. + +Abrir un nuevo fichero XML eliminará los resultados actuales. ¿Desea continuar? + + + XML files version 1 (*.xml) + Archivos XML versión 1 (*.xml) + + + XML files version 2 (*.xml) + Archivos XML versión 2 (*.xml) + + + Text files (*.txt) Ficheros de texto (*.txt) - + CSV files (*.csv) Ficheros CVS (*.cvs) - + Cppcheck - %1 + Cppcheck - %1 + + + Project files (*.cppcheck);;All files(*.*) Ficheros de proyecto (*.cppcheck;;Todos los ficheros (*.*) - + Select Project File Selecciona el archivo de proyecto - - - + + + Project: Proyecto: - + No suitable files found to analyze! - + C/C++ Source - + Compile database - + Visual Studio - + Borland C++ Builder 6 - + Select files to analyze - + Select directory to analyze - + Select the configuration that will be analyzed - + Found project files from the directory. Do you want to proceed analysis without using any of these project files? - + Current results will be cleared. Opening a new XML file will clear current results. @@ -1150,54 +1293,54 @@ Do you want to proceed? - + Analyzer is running. Do you want to stop the analysis and exit Cppcheck? - + About - + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) - + Build dir '%1' does not exist, create it? - + To check the project using addons, you need a build directory. - + Failed to import '%1', analysis is stopped - + Project files (*.cppcheck) - + Select Project Filename Selecciona el nombre del proyecto - + No project file loaded No hay ningún proyecto cargado - + The project file %1 @@ -1284,6 +1427,10 @@ Options: Platforms + + Built-in + Built-in + Native @@ -1315,6 +1462,21 @@ Options: Windows 64-bit + + Project + + Cppcheck + Cppcheck + + + Could not read the project file. + No se ha podido leer el fichero. + + + Could not write the project file. + No se ha podido escribir el fichero de proyecto. + + ProjectFile @@ -1322,6 +1484,10 @@ Options: Project File Archivo de proyecto + + Project + Proyecto + Paths and Defines @@ -1339,6 +1505,15 @@ Options: Defines must be separated by a semicolon ';' + + &Root: + Root: + Raíz: + + + Libraries: + Bibliotecas: + Note: Put your own custom .cfg files in the same folder as the project file. You should see them above. @@ -1498,6 +1673,14 @@ Options: External tools + + Includes + Incluir + + + Include directories: + Incluir los directorios: + Up @@ -1563,11 +1746,19 @@ Options: Libraries + + Exclude + Excluir + Suppressions Supresiones + + Suppression list: + Lista de supresiones: + Add @@ -1623,81 +1814,99 @@ Options: Archivo de proyecto: %1 - + Select Cppcheck build dir - + Select include directory Selecciona una carpeta para incluir - + Select a directory to check Selecciona la carpeta a comprobar - - (no rule texts file) - - - - + Clang-tidy (not found) - + Visual Studio - + Compile database - + Borland C++ Builder 6 - + Import Project - + Select directory to ignore Selecciona la carpeta a ignorar - + Source files - + All files - + Exclude file - + Add Suppression + Añadir supresión + + + Select MISRA rule texts file - + MISRA rule texts file (%1) + + QDialogButtonBox + + OK + Aceptar + + + Cancel + Cancelar + + + Close + Cerrar + + + Save + Guardar + + QObject @@ -1942,6 +2151,10 @@ Options: Please select the directory where file is located. + + [Inconclusive] + [No concluyente] + portability @@ -1967,6 +2180,22 @@ Options: Recheck + + Copy filename + Copiar nombre del archivo + + + Copy full path + Copiar ruta completa + + + Copy message + Copiar mensaje + + + Copy message id + Copiar id del mensaje + Hide @@ -2036,6 +2265,14 @@ Please check the application path and parameters are correct. No se ha podido ejecutar %1 Por favor comprueba que la ruta a la aplicación y los parámetros son correctos. + + + Could not find file: +%1 +Please select the directory where file is located. + No se ha encontrado el fichero: +%1 +Por favor selecciona la carpeta donde se encuentra. @@ -2095,6 +2332,14 @@ Por favor comprueba que la ruta a la aplicación y los parámetros son correctos Warning Details + + Functions + Funciones + + + No errors found, nothing to save. + No se han encontrado errores, nada que guardar. + @@ -2145,6 +2390,14 @@ Para cambiar el tipo de comportamiento, abra el menú Ver. XML format version 1 is no longer supported. + + Summary + Resumen + + + Message + Mensaje + First included by @@ -2333,6 +2586,14 @@ Para cambiar el tipo de comportamiento, abra el menú Ver. Custom + + Paths + Rutas + + + Include paths: + Rutas incluidas: + Add... @@ -2354,6 +2615,18 @@ Para cambiar el tipo de comportamiento, abra el menú Ver. Language Idioma + + Advanced + Avanzado + + + &Show inconclusive errors + &Mostrar errores no concluyentes + + + S&how internal warnings in log + M&ostrar advertencias internas en el log + Number of threads: @@ -2369,6 +2642,10 @@ Para cambiar el tipo de comportamiento, abra el menú Ver. Show "No errors found" message when no errors found Mostrar el mensaje "No se han encontrado errores" + + Edit + Editar + Remove @@ -2442,6 +2719,10 @@ Para cambiar el tipo de comportamiento, abra el menú Ver. Select clang path + + Select include directory + Seleccionar carpeta a incluir + StatsDialog diff --git a/gui/cppcheck_fi.ts b/gui/cppcheck_fi.ts index fb07ae9b8..6239db7f8 100644 --- a/gui/cppcheck_fi.ts +++ b/gui/cppcheck_fi.ts @@ -410,23 +410,30 @@ Parameters: -l(line) (file) + + LogView + + Cppcheck + Cppcheck + + MainWindow - - - - - - - - - - - - - + + + + + + + + + + + + + Cppcheck Cppcheck @@ -436,7 +443,7 @@ Parameters: -l(line) (file) - + Standard Vakio @@ -455,486 +462,494 @@ Parameters: -l(line) (file) &Toolbars + + &Check + &Tarkista + C++ standard - + &C standard C standard - + &Edit &Muokkaa - + &License... &Lisenssi... - + A&uthors... &Tekijät... - + &About... &Tietoa ohjelmasta Cppcheck... - + &Files... &Tiedostot... - - + + Analyze files Check files - + Ctrl+F Ctrl+F - + &Directory... &Hakemisto... - - + + Analyze directory Check directory - + Ctrl+D Ctrl+D - + &Recheck files + Tarkista tiedostot &uudelleen + + + Ctrl+R Ctrl+R - + &Stop &Pysäytä - - + + Stop analysis Stop checking - + Esc Esc - + &Save results to file... &Tallenna tulokset tiedostoon... - + Ctrl+S Ctrl+S - + &Quit &Lopeta - + &Clear results &Tyhjennä tulokset - + &Preferences &Asetukset - - + + Show errors - - + + Show warnings - - + + Show performance warnings - + Show &hidden - - + + Information - + Show information messages - + Show portability warnings - + Show Cppcheck results - + Clang - + Show Clang results - + &Filter - + Filter results - + Windows 32-bit ANSI - + Windows 32-bit Unicode - + Unix 32-bit - + Unix 64-bit - + Windows 64-bit - + &Print... - + Print the Current Report - + Print Pre&view... - + Open a Print Preview Dialog for the Current Results - + Open library editor - + &Check all &Valitse kaikki - + Filter - + &Reanalyze modified files &Recheck modified files - + Reanal&yze all files - + Ctrl+Q - + Style war&nings - + E&rrors - + &Uncheck all &Poista kaikista valinta - + Collapse &all &Pienennä kaikki - + &Expand all &Laajenna kaikki - + &Standard - + Standard items - + Toolbar - + &Categories - + Error categories - + &Open XML... - + Open P&roject File... - + Ctrl+Shift+O - + Sh&ow Scratchpad... - + &New Project File... - + Ctrl+Shift+N - + &Log View - + Log View - + C&lose Project File - + &Edit Project File... - + &Statistics - + &Warnings - + Per&formance warnings - + &Information - + &Portability - + P&latforms - + C++&11 - + C&99 - + &Posix - + C&11 - + &C89 - + &C++03 - + &Library Editor... - + &Auto-detect language - + &Enforce C++ - + E&nforce C - + C++14 - + Reanalyze and check library - + Check configuration (defines, includes) - + C++17 - + C++20 - + &Contents - + Categories - - + + Show style warnings - + Open the help contents - + F1 @@ -943,206 +958,227 @@ Parameters: -l(line) (file) &Help &Ohje + + Select directory to check + Valitse tarkistettava hakemisto + + + No suitable files found to check! + Tarkistettavaksi sopivia tiedostoja ei löytynyt! + - + Quick Filter: - + Select configuration - + Found project file: %1 Do you want to load this project file instead? - + File not found - + Bad XML - + Missing attribute - + Bad attribute value - + Failed to load the selected library '%1'. %2 - + License Lisenssi - + Authors Tekijät - + XML files version 2 (*.xml);;XML files version 1 (*.xml);;Text files (*.txt);;CSV files (*.csv) + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) + XML-tiedostot (*.xml);;Tekstitiedostot (*.txt);;CSV-tiedostot (*.csv) + + + Save the report file Tallenna raportti - - + + XML files (*.xml) XML-tiedostot (*xml) - + There was a problem with loading the editor application settings. This is probably because the settings were changed between the Cppcheck versions. Please check (and fix) the editor application settings, otherwise the editor program might not start correctly. - + You must close the project file before selecting new files or directories! - + Select files to check + Valitse tarkistettavat tiedostot + + + The library '%1' contains unknown elements: %2 - + Unsupported format - + Duplicate platform type - + Platform type redefined - + Unknown element - + Unknown issue - + Error - + Failed to load %1. Your Cppcheck installation is broken. You can use --data-dir=<directory> at the command line to specify where this file is located. Please note that --data-dir is supposed to be used by installation scripts and therefore the GUI does not start when it is used, all that happens is that the setting is configured. - + Open the report file - + Text files (*.txt) Tekstitiedostot (*.txt) - + CSV files (*.csv) - + Cppcheck - %1 + Cppcheck - %1 + + + Project files (*.cppcheck);;All files(*.*) - + Select Project File - - - + + + Project: - + No suitable files found to analyze! - + C/C++ Source - + Compile database - + Visual Studio - + Borland C++ Builder 6 - + Select files to analyze - + Select directory to analyze - + Select the configuration that will be analyzed - + Found project files from the directory. Do you want to proceed analysis without using any of these project files? - + Current results will be cleared. Opening a new XML file will clear current results. @@ -1150,54 +1186,54 @@ Do you want to proceed? - + Analyzer is running. Do you want to stop the analysis and exit Cppcheck? - + About - + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) - + Build dir '%1' does not exist, create it? - + To check the project using addons, you need a build directory. - + Failed to import '%1', analysis is stopped - + Project files (*.cppcheck) - + Select Project Filename - + No project file loaded - + The project file %1 @@ -1309,6 +1345,13 @@ Options: + + Project + + Cppcheck + Cppcheck + + ProjectFile @@ -1617,77 +1660,72 @@ Options: - + Select Cppcheck build dir - + Select include directory - + Select a directory to check - - (no rule texts file) - - - - + Clang-tidy (not found) - + Visual Studio - + Compile database - + Borland C++ Builder 6 - + Import Project - + Select directory to ignore - + Source files - + All files - + Exclude file - + Select MISRA rule texts file - + MISRA rule texts file (%1) @@ -1953,6 +1991,14 @@ Options: Recheck + + Copy filename + Kopioi tiedostonimi + + + Copy full path + Kopioi tiedoston koko polku + Hide @@ -2146,6 +2192,10 @@ Määrittääksesi minkä tyyppisiä virheitä näytetään, avaa näkymä valik Copy complete Log + + No errors found, nothing to save. + Virheitä ei löytynyt, ei mitään tallennettavaa. + diff --git a/gui/cppcheck_fr.ts b/gui/cppcheck_fr.ts index 0767e1e3e..7811e8095 100644 --- a/gui/cppcheck_fr.ts +++ b/gui/cppcheck_fr.ts @@ -420,19 +420,19 @@ Paramètres : -l(ligne) (fichier) MainWindow - - - - - - - - - - - - - + + + + + + + + + + + + + Cppcheck @@ -452,158 +452,174 @@ Paramètres : -l(ligne) (fichier) &Aide - + &Check + &Vérifier + + + &Edit &Édition - + Standard Standard - + &License... &Licence... - + A&uthors... A&uteurs... - + &About... À &Propos... - + &Files... &Fichiers... - + Ctrl+F - + &Directory... &Répertoires... - + Ctrl+D - + &Recheck files + &Revérifier les fichiers + + + Ctrl+R - + &Stop &Arrêter - + Esc - + &Save results to file... &Sauvegarder les résultats dans un fichier... - + Ctrl+S - + &Quit &Quitter - + &Clear results &Effacer les résultats - + &Preferences &Préférences - + &Check all &Tout cocher - + &Uncheck all &Tout décocher - + Collapse &all &Tout réduire - + &Expand all &Tout dérouler - + &Contents &Contenus - + Open the help contents Ouvir l'aide - + F1 - + No suitable files found to check! + Pas de fichiers trouvés à vérifier ! + + + Select directory to check + Sélectionner le répertoire à vérifier + + + License Licence - + Authors Auteurs - + Save the report file Sauvegarder le rapport - - + + XML files (*.xml) Fichiers XML (*.xml) - + About - + Text files (*.txt) Fichiers Texte (*.txt) - + CSV files (*.csv) Fichiers CSV (*.csv) @@ -613,180 +629,220 @@ Paramètres : -l(ligne) (fichier) &Boite à outils - + Categories Catégories - - + Check files + Vérifier les fichiers + + + Check directory + Vérifier un répertoire + + + Stop checking + Arrêter la vérification + + + Style warnings + Avertissement de style + + + + Show style warnings Afficher les avertissements de style - - + Errors + Erreurs + + + + Show errors Afficher les erreurs - + &Standard - + Standard items - + Toolbar - + &Categories - + Error categories - + &Open XML... &Ouvrir un fichier XML... - + Open P&roject File... Ouvrir un P&rojet... - + &New Project File... &Nouveau Projet... - + &Log View &Journal - + Log View Journal - + C&lose Project File F&ermer le projet - + &Edit Project File... &Editer le projet - + &Statistics Statistiques - - + Warnings + Avertissements + + + + Show warnings Afficher les avertissements - - + Performance warnings + Avertissements de performance + + + + Show performance warnings Afficher les avertissements de performance - + Show &hidden - - + + Information Information - + Show information messages Afficher les messages d'information - + Portability + Portabilité + + + Show portability warnings Afficher les problèmes de portabilité - + You must close the project file before selecting new files or directories! Vous devez d'abord fermer le projet avant de choisir des fichiers/répertoires - + Open the report file Ouvrir le rapport - + Checking is running. + +Do you want to stop the checking and exit Cppcheck? + Vérification en cours. + +Voulez-vous arrêter la vérification et quitter CppCheck ? + + + Project files (*.cppcheck);;All files(*.*) - + Select Project File - + To check the project using addons, you need a build directory. - + Select Project Filename - + No project file loaded - + There was a problem with loading the editor application settings. This is probably because the settings were changed between the Cppcheck versions. Please check (and fix) the editor application settings, otherwise the editor program might not start correctly. - + &Filter &Filtre - + Filter results - + Quick Filter: Filtre rapide : - + Found project file: %1 Do you want to load this project file instead? @@ -794,14 +850,14 @@ Do you want to load this project file instead? - - - + + + Project: Projet : - + The project file %1 @@ -812,35 +868,47 @@ Do you want to remove the file from the recently used projects -list? - + Filter Filtre - + Windows 32-bit ANSI - + Windows 32-bit Unicode - + Unix 32-bit - + Unix 64-bit - + Windows 64-bit + + Current results will be cleared. + +Opening a new XML file will clear current results.Do you want to proceed? + Les résultats courant seront effacés. + +L'ouverture d'un nouveau fichier XML effacera les resultats. Voulez-vous confirmar l'opération ? + + + Select files to check + Sélectionner les fichiers à vérifier + Cppcheck GUI - Command line parameters @@ -852,96 +920,108 @@ Do you want to remove the file from the recently used projects -list? - + Error Erreur - + File not found Fichier introuvable - + Bad XML Mauvais fichier XML - + Missing attribute Attribut manquant - + Bad attribute value Mauvaise valeur d'attribut - + Failed to load the selected library '%1'. %2 Echec lors du chargement de la bibliothèque '%1'. %2 - + Unsupported format Format non supporté - + The library '%1' contains unknown elements: %2 La bibliothèque '%1' contient des éléments inconnus: %2 - + Duplicate platform type - + Platform type redefined - + &Print... &Imprimer... - + Print the Current Report Imprimer le rapport - + Print Pre&view... Apercu d'impression... - + Open a Print Preview Dialog for the Current Results - + Open library editor - + Auto-detect language + Auto-detection du langage + + + &Recheck modified files + &Revérifier les fichiers modifiés + + + &Recheck all files + &Revérifier tous les fichiers + + + Unknown element - + Unknown issue - + Select configuration @@ -964,72 +1044,72 @@ Options: - + Failed to load %1. Your Cppcheck installation is broken. You can use --data-dir=<directory> at the command line to specify where this file is located. Please note that --data-dir is supposed to be used by installation scripts and therefore the GUI does not start when it is used, all that happens is that the setting is configured. - + Build dir '%1' does not exist, create it? - - + + Analyze files - - + + Analyze directory - + &Reanalyze modified files - - + + Stop analysis - + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) - + No suitable files found to analyze! - + Select files to analyze - + Select directory to analyze - + Select the configuration that will be analyzed - + Found project files from the directory. Do you want to proceed analysis without using any of these project files? - + Analyzer is running. Do you want to stop the analysis and exit Cppcheck? @@ -1041,192 +1121,192 @@ Do you want to stop the analysis and exit Cppcheck? - + &C standard - + Reanal&yze all files - + Ctrl+Q - + Style war&nings - + E&rrors - + Ctrl+Shift+O - + Sh&ow Scratchpad... - + Ctrl+Shift+N - + &Warnings - + Per&formance warnings - + &Information - + &Portability - + Show Cppcheck results - + Clang - + Show Clang results - + P&latforms - + C++&11 - + C&99 - + &Posix - + C&11 - + &C89 - + &C++03 - + &Library Editor... - + &Auto-detect language - + &Enforce C++ - + E&nforce C - + C++14 - + Failed to import '%1', analysis is stopped - + Project files (*.cppcheck) - + Reanalyze and check library - + Check configuration (defines, includes) - + C++17 - + C++20 - + C/C++ Source - + Compile database - + Visual Studio - + Borland C++ Builder 6 - + Current results will be cleared. Opening a new XML file will clear current results. @@ -1300,6 +1380,17 @@ Do you want to proceed? + + Project + + Could not read the project file. + Impossible de lire le fichier projet. + + + Could not write the project file. + Impossible d'écrire dans le fichier projet. + + ProjectFile @@ -1317,6 +1408,10 @@ Do you want to proceed? Defines: + + Project + Projet + @@ -1338,6 +1433,18 @@ Do you want to proceed? Remove Supprimer + + Includes + Inclusions + + + Include directories: + Inclure les répertoires + + + Root: + Répertoire racine + Up @@ -1348,11 +1455,23 @@ Do you want to proceed? Down Descendre + + Exclude + Exclure + + + Libraries: + Bibliothèques + Suppressions Suppressions + + Suppression list: + Liste de suppressions + Add @@ -1606,81 +1725,95 @@ Do you want to proceed? Fichier projet : %1 - + Select include directory Selectionner un répertoire à inclure - + Select directory to ignore Selectionner un répertoire à ignorer - + Select a directory to check Selectionner un répertoire à vérifier - + Select Cppcheck build dir - + Import Project - + Clang-tidy (not found) - - (no rule texts file) - - - - + Source files - + All files - + Exclude file - + Select MISRA rule texts file - + MISRA rule texts file (%1) - + Visual Studio - + Compile database - + Borland C++ Builder 6 + + QDialogButtonBox + + OK + OK + + + Cancel + Annuler + + + Close + Fermer + + + Save + Sauvegarder + + QObject @@ -1894,6 +2027,18 @@ Do you want to proceed? Undefined file Fichier indéterminé + + Copy filename + Copier le nom du fichier + + + Copy full path + Copier le chemin complet + + + Copy message + Copier le message + @@ -1934,6 +2079,14 @@ Merci de vérifier que le chemin de l'application et que les paramètres so Could not find the file! Fichier introuvable ! + + Could not find file: +%1 +Please select the directory where file is located. + Fichier introuvable: +%1 +Veuillez sélectionner le répertoire où est situé le fichier. + Select Directory @@ -1983,6 +2136,10 @@ Please select the default editor application in preferences/Applications.Id Id + + Copy message id + Copier l'identifiant du message + Hide all with id @@ -2085,6 +2242,10 @@ Pour configurer les erreurs affichées, ouvrez le menu d'affichage.Bug hunting analysis is incomplete + + No errors found, nothing to save. + Pas d'erreurs trouvées, rien à sauvegarder. + @@ -2097,6 +2258,14 @@ Pour configurer les erreurs affichées, ouvrez le menu d'affichage.Failed to read the report. Erreur lors de la lecture du rapport + + Summary + Résumé + + + Message + Message + %p% (%1 of %2 files checked) @@ -2228,6 +2397,10 @@ Pour configurer les erreurs affichées, ouvrez le menu d'affichage.Save full path to files in reports Sauvegarder le chemin complet des fichiers dans les rapports + + Include paths: + Inclure les chemins + Add... @@ -2253,6 +2426,14 @@ Pour configurer les erreurs affichées, ouvrez le menu d'affichage.Language Langue + + Paths + Chemins + + + Edit + Editer + Remove @@ -2389,6 +2570,10 @@ Pour configurer les erreurs affichées, ouvrez le menu d'affichage.N/A + + Select include directory + Selectionner un répertoire à inclure + [Default] diff --git a/gui/cppcheck_it.ts b/gui/cppcheck_it.ts index 1db66defb..2269eb7bd 100644 --- a/gui/cppcheck_it.ts +++ b/gui/cppcheck_it.ts @@ -419,23 +419,50 @@ Parametri: -l(line) (file) + + LogView + + Checking Log + Log sulla scansione + + + Clear + Cancella + + + Save Log + Salva il rapporto + + + Text files (*.txt *.log);;All files (*.*) + File di testo (*.txt *.log);;Tutti i files(*.*) + + + Cppcheck + Cppcheck + + + Could not open file for writing: "%1" + Non è stato possibile aprire il file per la scrittura: "%1" + + MainWindow - - - - - - - - - - - - - + + + + + + + + + + + + + Cppcheck Cppcheck @@ -445,7 +472,7 @@ Parametri: -l(line) (file) - + Standard Standard @@ -464,486 +491,546 @@ Parametri: -l(line) (file) &Toolbars &Barre degli strumenti + + &Check + &Scansiona + C++ standard - + &C standard C standard - + &Edit &Modifica - + &License... &Licenza... - + A&uthors... A&utori... - + &About... I&nformazioni su... - + &Files... &File... - - + + Analyze files Check files Scansiona i file - + Ctrl+F Ctrl+F - + &Directory... &Cartella... - - + + Analyze directory Check directory Scansiona la cartella - + Ctrl+D Ctrl+D - + &Recheck files + &Riscansiona i file + + + Ctrl+R Ctrl+R - + &Stop &Ferma - - + + Stop analysis Stop checking Ferma la scansione - + Esc Esc - + &Save results to file... &Salva i risultati nel file... - + Ctrl+S Ctrl+S - + &Quit &Esci - + &Clear results &Cancella i risultati - + &Preferences &Preferenze - - + Errors + Errori + + + + Show errors Mostra gli errori - - + Show S&cratchpad... + Mostra il blocchetto per appunti... + + + Warnings + Avvisi + + + + Show warnings Mostra gli avvisi - - + Performance warnings + Avvisi sulle prestazioni + + + + Show performance warnings Mostra gli avvisi sulle prestazioni - + Show &hidden Mostra &i nascosti - - + + Information Informazione - + Show information messages Mostra messaggi di informazione - + Portability + Portabilità + + + Show portability warnings Mostra gli avvisi sulla portabilità - + Show Cppcheck results - + Clang - + Show Clang results - + &Filter &Filtro - + Filter results Filtra i risultati - + Windows 32-bit ANSI Windows 32-bit, ANSI - + Windows 32-bit Unicode Windows 32-bit, Unicode - + Unix 32-bit Unix 32-bit - + Unix 64-bit Unix 64-bit - + Windows 64-bit Windows 64-bit - + Platforms + Piattaforme + + + C++11 + C++11 + + + C99 + C99 + + + Posix + Posix + + + C11 + C11 + + + C89 + C89 + + + C++03 + C++03 + + + &Print... - + Print the Current Report - + Print Pre&view... - + Open a Print Preview Dialog for the Current Results - + Open library editor - + &Check all &Seleziona tutto - + Filter Filtro - + &Reanalyze modified files &Recheck modified files - + Reanal&yze all files - + Ctrl+Q - + Style war&nings - + E&rrors - + &Uncheck all &Deseleziona tutto - + Collapse &all Riduci &tutto - + &Expand all &Espandi tutto - + &Standard &Standard - + Standard items Oggetti standard - + Toolbar Barra degli strumenti - + &Categories &Categorie - + Error categories Categorie di errore - + &Open XML... &Apri XML... - + Open P&roject File... Apri file di p&rogetto... - + Ctrl+Shift+O - + Sh&ow Scratchpad... - + &New Project File... &Nuovo file di progetto... - + Ctrl+Shift+N - + &Log View &Visualizza il rapporto - + Log View Visualizza il rapporto - + C&lose Project File C&hiudi il file di progetto - + &Edit Project File... &Modifica il file di progetto... - + &Statistics &Statistiche - + &Warnings - + Per&formance warnings - + &Information - + &Portability - + P&latforms - + C++&11 - + C&99 - + &Posix - + C&11 - + &C89 - + &C++03 - + &Library Editor... - + &Auto-detect language - + &Enforce C++ - + E&nforce C - + C++14 C++14 - + Reanalyze and check library - + Check configuration (defines, includes) - + C++17 C++17 - + C++20 C++20 - + &Contents &Contenuti - + Categories Categorie - - + Style warnings + Avvisi sullo stile + + + + Show style warnings Mostra gli avvisi sullo stile - + Open the help contents Apri i contenuti di aiuto - + F1 F1 @@ -952,19 +1039,27 @@ Parametri: -l(line) (file) &Help &Aiuto + + Select directory to check + Seleziona una cartella da scansionare + + + No suitable files found to check! + Nessun file trovato idoneo alla scansione! + - + Quick Filter: Rapido filtro: - + Select configuration - + Found project file: %1 Do you want to load this project file instead? @@ -973,59 +1068,71 @@ Do you want to load this project file instead? Vuoi piuttosto caricare questo file di progetto? - + Found project files from the directory. + +Do you want to proceed checking without using any of these project files? + Trovati file di progetto dalla directory. + +Vuoi procedere alla scansione senza usare qualcuno di questi file di progetto? + + + File not found - + Bad XML - + Missing attribute - + Bad attribute value - + Unsupported format - + Failed to load the selected library '%1'. %2 - + License Licenza - + Authors Autori - + XML files version 2 (*.xml);;XML files version 1 (*.xml);;Text files (*.txt);;CSV files (*.csv) + File XML Versione 2 (*.xml);;File XML Versione 1 (*.xml);;File di testo (*.txt);;File CSV (*.csv) + + + Save the report file Salva il file di rapporto - - + + XML files (*.xml) File XML (*.xml) - + There was a problem with loading the editor application settings. This is probably because the settings were changed between the Cppcheck versions. Please check (and fix) the editor application settings, otherwise the editor program might not start correctly. @@ -1034,128 +1141,172 @@ This is probably because the settings were changed between the Cppcheck versions Probabilmente ciò è avvenuto perché le impostazioni sono state modificate tra le versioni di Cppcheck. Per favore controlla (e sistema) le impostazioni delle applicazioni editor, altrimenti il programma editor può non partire correttamente. - + You must close the project file before selecting new files or directories! Devi chiudere il file di progetto prima di selezionare nuovi file o cartelle! - + Select files to check + Seleziona i file da scansionare + + + The library '%1' contains unknown elements: %2 - + Duplicate platform type - + Platform type redefined - + Unknown element - + Unknown issue - + Error - + Failed to load %1. Your Cppcheck installation is broken. You can use --data-dir=<directory> at the command line to specify where this file is located. Please note that --data-dir is supposed to be used by installation scripts and therefore the GUI does not start when it is used, all that happens is that the setting is configured. - + Current results will be cleared. + +Opening a new XML file will clear current results.Do you want to proceed? + I risultati correnti verranno ripuliti. + +L'apertura di un nuovo file XML ripulirà i risultati correnti. Vuoi procedere? + + + Open the report file Apri il file di rapporto - + Checking is running. + +Do you want to stop the checking and exit Cppcheck? + La scansione è in esecuzione. + +Vuoi fermare la scansione ed uscire da Cppcheck? + + + XML files version 1 (*.xml) + Files XML versione 1 (*.xml) + + + XML files version 2 (*.xml) + Files XML versione 2 (*.xml) + + + Text files (*.txt) File di testo (*.txt) - + CSV files (*.csv) Files CSV (*.csv) - + Cppcheck - %1 + Cppcheck - %1 + + + Failed to change the user interface language: + +%1 + +The user interface language has been reset to English. Open the Preferences-dialog to select any of the available languages. + Fallito il tentativo di cambio della lingua dell'interfaccia utente: + +%1 + +L'interfaccia utente è stata risettata in Inglese. Apri la finestra di dialogo Preferenze per selezionare una qualunque lingua a disposizione. + + + Project files (*.cppcheck);;All files(*.*) Files di progetto (*.cppcheck);;Tutti i files(*.*) - + Select Project File Seleziona il file di progetto - - - + + + Project: Progetto: - + No suitable files found to analyze! - + C/C++ Source - + Compile database - + Visual Studio - + Borland C++ Builder 6 - + Select files to analyze - + Select directory to analyze - + Select the configuration that will be analyzed - + Found project files from the directory. Do you want to proceed analysis without using any of these project files? - + Current results will be cleared. Opening a new XML file will clear current results. @@ -1163,54 +1314,54 @@ Do you want to proceed? - + Analyzer is running. Do you want to stop the analysis and exit Cppcheck? - + About - + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) - + Build dir '%1' does not exist, create it? - + To check the project using addons, you need a build directory. - + Failed to import '%1', analysis is stopped - + Project files (*.cppcheck) - + Select Project Filename Seleziona il nome del file di progetto - + No project file loaded Nessun file di progetto caricato - + The project file %1 @@ -1297,6 +1448,10 @@ Options: Platforms + + Built-in + Built-in + Native @@ -1328,6 +1483,21 @@ Options: Windows 64-bit + + Project + + Cppcheck + Cppcheck + + + Could not read the project file. + Non è stato possibile leggere il file di progetto. + + + Could not write the project file. + Non è stato possibile scrivere il file di progetto. + + ProjectFile @@ -1335,6 +1505,10 @@ Options: Project File File di progetto + + Project + Progetto + Paths and Defines @@ -1352,6 +1526,11 @@ Options: Defines must be separated by a semicolon ';' + + &Root: + Root: + Root: + Note: Put your own custom .cfg files in the same folder as the project file. You should see them above. @@ -1511,6 +1690,14 @@ Options: External tools + + Includes + Inclusioni + + + Include directories: + Cartelle di inclusione: + Up @@ -1576,6 +1763,10 @@ Options: Libraries + + Exclude + Escludi + Suppressions @@ -1636,81 +1827,83 @@ Options: File di progetto: %1 - + Select Cppcheck build dir - + Select include directory Seleziona la cartella da includere - + Select a directory to check Seleziona una cartella da scansionare - - (no rule texts file) - - - - + Clang-tidy (not found) - + Visual Studio - + Compile database - + Borland C++ Builder 6 - + Import Project - + Select directory to ignore Seleziona la cartella da ignorare - + Source files - + All files - + Exclude file - + Select MISRA rule texts file - + MISRA rule texts file (%1) + + QDialogButtonBox + + Close + Chiudi + + QObject @@ -1955,6 +2148,10 @@ Options: Please select the directory where file is located. + + [Inconclusive] + [Inconcludente] + debug @@ -1970,6 +2167,22 @@ Options: Recheck + + Copy filename + Copia nome file + + + Copy full path + Copia tutto il percorso + + + Copy message + Copia messaggio + + + Copy message id + Copia id del messaggio + Hide @@ -2038,6 +2251,14 @@ Please check the application path and parameters are correct. Non è stato possibile avviare %1 Per favore verifica che il percorso dell'applicazione e i parametri siano corretti. + + + Could not find file: +%1 +Please select the directory where file is located. + Non è stato possibile trovare il file: +%1 +Per favore selezioa la cartella dove il file è posizionato. @@ -2136,6 +2357,14 @@ Per vedere il tipo di errori che sono mostrati, apri il menu Visualizza.XML format version 1 is no longer supported. + + Summary + Riassunto + + + Message + Messaggio + First included by @@ -2166,6 +2395,10 @@ Per vedere il tipo di errori che sono mostrati, apri il menu Visualizza.Copy complete Log + + No errors found, nothing to save. + Nessun errore trovato, nulla da salvare. + @@ -2228,6 +2461,10 @@ Per vedere il tipo di errori che sono mostrati, apri il menu Visualizza.General Generale + + Include paths: + Percorsi d'inclusione: + Add... @@ -2365,6 +2602,14 @@ Per vedere il tipo di errori che sono mostrati, apri il menu Visualizza.Custom + + Paths + Percorsi + + + Edit + Modifica + Remove @@ -2406,6 +2651,18 @@ Per vedere il tipo di errori che sono mostrati, apri il menu Visualizza.Language Lingua + + Advanced + Avanzate + + + &Show inconclusive errors + &Mostra errori inconcludenti + + + S&how internal warnings in log + &Mostra avvisi interni nel log + SettingsDialog @@ -2454,6 +2711,10 @@ Per vedere il tipo di errori che sono mostrati, apri il menu Visualizza.Select clang path + + Select include directory + Seleziona la cartella da includere + StatsDialog diff --git a/gui/cppcheck_ja.ts b/gui/cppcheck_ja.ts index 66cb9d308..77bba1e2d 100644 --- a/gui/cppcheck_ja.ts +++ b/gui/cppcheck_ja.ts @@ -38,7 +38,29 @@ of the GNU General Public License version 3 <html><head/><body><p>Many thanks to these libraries that we use:</p><ul style="margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; -qt-list-indent: 1;"><li style=" margin-top:12px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">pcre</li><li style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">picojson</li><li style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">qt</li><li style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">tinyxml2</li></ul></body></html> - <html><head/><body><p>ライブラリの開発者に感謝を捧げます:</p><ul style="margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; -qt-list-indent: 1;"><li style=" margin-top:12px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">pcre</li><li style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">picojson</li><li style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">qt</li><li style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">tinyxml2</li></ul></body></html> + + + + <html><head/><body> +<p>Many thanks to these libraries that we use:</p><ul> +<li>pcre</li> +<li>picojson</li> +<li>qt</li> +<li>tinyxml2</li> +<li>z3</li></ul></body></html> + <html><head/><body> +<p>Many thanks to these libraries that we use:</p><ul> +<li>tinyxml2</li> +<li>picojson</li> +<li>pcre</li> +<li>qt</li></ul></body></html> + <html><head/><body> +<p>私達は以下のライブラリを使用しています。ここで感謝の意を表明します。</p><ul> +<li>pcre</li> +<li>picojson</li> +<li>qt</li> +<li>tinyxml2</li> +<li>z3</li></ul></body></html> @@ -134,6 +156,21 @@ Parameters: -l(line) (file) ファイル:%1 が読み込めません + + FunctionContractDialog + + Function contract + 関数の構成 + + + Name + 名前 + + + Requirements for parameters + パラメータの要求事項 + + HelpDialog @@ -394,6 +431,10 @@ Parameters: -l(line) (file) argvalue argvalue(引数の値) + + constant + constant(定数) + @@ -429,23 +470,50 @@ Parameters: -l(line) (file) 妥当な値 + + LogView + + Checking Log + Cppcheck ログ + + + Clear + 消去 + + + Save Log + ログ保存 + + + Text files (*.txt *.log);;All files (*.*) + テキストファイル (*.txt *.log);;すべてのファイル(*.*) + + + Cppcheck + Cppcheck + + + Could not open file for writing: "%1" + ファイルを書き込みできない + + MainWindow - - - - - - - - - - - - - + + + + + + + + + + + + + Cppcheck Cppcheck @@ -469,265 +537,338 @@ Parameters: -l(line) (file) &Help ヘルプ(&H) + + &Check + 解析(&A) + C++ standard C++標準 - + &C standard C standard &C標準 - + &Edit 編集(&E) - + Standard 言語規格 - + Categories カテゴリ - + &License... ライセンス(&L)... - + A&uthors... 作者(&u)... - + &About... Cppcheckについて(&A)... - + &Files... ファイル選択(&F)... - - + + Analyze files Check files ファイルをチェックする - + Ctrl+F Ctrl+F - + &Directory... ディレクトリ選択(&D)... - - + + Analyze directory Check directory ディレクトリをチェックする - + Ctrl+D Ctrl+D - + &Recheck files + 再チェック(&R) + + + Ctrl+R Ctrl+R - + &Reanalyze all files + &Recheck all files + 全ファイル再チェック + + + &Stop 停止(&S) - - + + Stop analysis Stop checking チェックを停止する - + Esc Esc - + &Save results to file... 結果をファイルに保存(&S)... - + Ctrl+S Ctrl+S - + &Quit 終了(&Q) - + &Clear results 結果をクリア(&C) - + &Preferences 設定(&P) - - + Style warnings + スタイル警告 + + + + Show style warnings スタイル警告を表示 - - + Errors + エラー + + + + Show errors エラーを表示 - - + Show S&cratchpad... + スクラッチパッドを表示 + + + + Information 情報 - + Show information messages 情報メッセージを表示 - + Portability + 移植可能性 + + + Show portability warnings 移植可能性の問題を表示 - + Show Cppcheck results Cppcheck結果を表示する - + Clang Clang - + Show Clang results Clangの結果を表示 - + &Filter フィルター(&F) - + Filter results フィルタ結果 - + Windows 32-bit ANSI Windows 32-bit ANSIエンコード - + Windows 32-bit Unicode Windows 32-bit Unicode - + Unix 32-bit Unix 32-bit - + Unix 64-bit Unix 64-bit - + Windows 64-bit Windows 64-bit - + Platforms + プラットフォーム + + + C++11 + C++11 + + + C99 + C99 + + + Posix + Posix + + + C11 + C11 + + + C89 + C89 + + + C++03 + C++03 + + + &Print... 印刷(&P)... - + Print the Current Report 現在のレポートを印刷 - + Print Pre&view... 印刷プレビュー(&v)... - + Open a Print Preview Dialog for the Current Results 現在のレポートをプレビュー表示 - + Library Editor... + ライブラリの編集 + + + Open library editor ライブラリエディタを開く - + Auto-detect language + 言語を自動検出 + + + C&lose Project File プロジェクトを閉じる(&l) - + &Edit Project File... プロジェクトの編集(&E)... - + &Statistics 統計情報(&S) - - + Warnings + 警告 + + + + Show warnings 警告を表示 - - + Performance warnings + パフォーマンス警告 + + + + Show performance warnings パフォーマンス警告を表示 - + Show &hidden 非表示を表示(&h) - + &Check all すべてのエラーを表示(&C) @@ -737,233 +878,233 @@ Parameters: -l(line) (file) チェック(&n) - + Filter フィルター - + &Reanalyze modified files &Recheck modified files 変更ありファイルを再解析(&R) - + Reanal&yze all files 全ファイル再解析(&y) - + Ctrl+Q Ctrl+Q - + Style war&nings スタイル警告(&n) - + E&rrors エラー(&r) - + &Uncheck all すべてのエラーを非表示(&U) - + Collapse &all ツリーを折り畳む(&a) - + &Expand all ツリーを展開(&E) - + &Standard 言語規格(&S) - + Standard items 標準項目 - + &Contents コンテンツ(&C) - + Open the help contents ヘルプファイルを開く - + F1 F1 - + Toolbar ツールバー - + &Categories カテゴリ(&C) - + Error categories エラーカテゴリ - + &Open XML... XMLを開く(&O)... - + Open P&roject File... プロジェクトを開く(&R)... - + Ctrl+Shift+O Ctrl+Shift+O - + Sh&ow Scratchpad... スクラッチパッドを表示(&o)... - + &New Project File... 新規プロジェクト(&N)... - + Ctrl+Shift+N Ctrl+Shift+N - + &Log View ログを表示(&L) - + Log View ログ表示 - + &Warnings 警告(&W) - + Per&formance warnings パフォーマンス警告(&f) - + &Information 情報(&I) - + &Portability 移植可能性(&P) - + P&latforms プラットフォーム(&l) - + C++&11 C++11(&1) - + C&99 C99(&9) - + &Posix Posix(&P) - + C&11 C11(&1) - + &C89 C89(&C) - + &C++03 C++03(&C) - + &Library Editor... ライブラリエディタ(&L)... - + &Auto-detect language 自動言語検出(&A) - + &Enforce C++ C++ 強制(&E) - + E&nforce C C 強制(&n) - + C++14 C++14 - + Reanalyze and check library ライブラリを再チェックする - + Check configuration (defines, includes) チェックの設定(define、インクルード) - + C++17 C++17 - + C++20 C++20 - + There was a problem with loading the editor application settings. This is probably because the settings were changed between the Cppcheck versions. Please check (and fix) the editor application settings, otherwise the editor program might not start correctly. @@ -972,23 +1113,43 @@ This is probably because the settings were changed between the Cppcheck versions Cppcheckの古いバージョンの設定には互換性がありません。エディタアプリケーションの設定を確認して修正してください、そうしないと正しく起動できないかもしれません。 - + No suitable files found to check! + 解析可能なファイルではありません + + + You must close the project file before selecting new files or directories! 新しいファイル/ディレクトリをチェックするには現在のプロジェクトを閉じてください! + + C/C++ Source, Compile database, Visual Studio (%1 %2 *.sln *.vcxproj) + C/C++ソースコード、プロジェクトファイル、Visual Studioソリューション(%1 %2 *.sln *.vcxproj) + + + Select directory to check + チェック対象のディレクトリを選択 + - + Quick Filter: クイックフィルタ: - + Select files to check + チェック対象のファイルを選択 + + + C/C++ Source (%1) + C/C++ ソース (%1) + + + Select configuration コンフィグレーションの選択 - + Found project file: %1 Do you want to load this project file instead? @@ -997,170 +1158,216 @@ Do you want to load this project file instead? 現在のプロジェクトの代わりにこのプロジェクトファイルを読み込んでもかまいませんか? - + Found project files from the directory. + +Do you want to proceed checking without using any of these project files? + ディレクトリからプロジェクトファイルが検出されました。 + +これらのプロジェクトファイルを使用せずに解析を進めてもかまいませんか? + + + + The library '%1' contains unknown elements: %2 このライブラリ '%1' には次の不明な要素が含まれています。 %2 - + File not found ファイルがありません - + Bad XML 不正なXML - + Missing attribute 属性がありません - + Bad attribute value 不正な属性があります - + Unsupported format サポートされていないフォーマット - + Duplicate platform type プラットフォームの種類が重複しています - + Platform type redefined プラットフォームの種類が再定義されました - + Unknown element 不明な要素 - + Unknown issue 不明な課題 - + Failed to load the selected library '%1'. %2 選択したライブラリの読み込みに失敗しました '%1' %2 - + Error エラー - + Failed to load %1. Your Cppcheck installation is broken. You can use --data-dir=<directory> at the command line to specify where this file is located. + %1の読み込みに失敗しました。CppCheckのインストールに失敗しています。コマンドライン引数に --data-dir=<directory> を指定して、このファイルの場所を指定してください。 + + + Failed to load %1. Your Cppcheck installation is broken. You can use --data-dir=<directory> at the command line to specify where this file is located. Please note that --data-dir is supposed to be used by installation scripts and therefore the GUI does not start when it is used, all that happens is that the setting is configured. %1のロードに失敗しました。あなたの Cppcheck は正しくインストールされていません。あなたは --data-dir=<directory> コマンドラインオプションでロードするファイルの場所を指定できます。ただし、この --data-dir はインストールスクリプトによってサポートされており、GUI版ではサポートされていません。全ての設定は調整済みでなければなりません。 - - + Current results will be cleared. + +Opening a new XML file will clear current results.Do you want to proceed? + 現在の結果を作成します。 + +新しくXMLファイルを開くと現在の結果が削除されます。実行しますか? + + + + XML files (*.xml) XML ファイル (*.xml) - + Open the report file レポートを開く - + Checking is running. + +Do you want to stop the checking and exit Cppcheck? + 解析中です. + +解析を停止してCppcheckを終了しますか?. + + + License ライセンス - + Authors 作者 - + XML files version 2 (*.xml);;XML files version 1 (*.xml);;Text files (*.txt);;CSV files (*.csv) + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) + XML ファイル (*.xml);;テキストファイル (*.txt);;CSV形式ファイル (*.csv) + + + Save the report file レポートを保存 - + XML files version 1 (*.xml) + XMLファイルのバージョン1 + + + XML files version 2 (*.xml) + XMLファイルのバージョン2 + + + Text files (*.txt) テキストファイル (*.txt) - + CSV files (*.csv) CSV形式ファイル (*.csv) - + Cppcheck - %1 + Cppcheck - %1 + + + Project files (*.cppcheck);;All files(*.*) プロジェクトファイル (*.cppcheck);;すべてのファイル(*.*) - + Select Project File プロジェクトファイルを選択 - - - + + + Project: プロジェクト: - + No suitable files found to analyze! チェック対象のファイルがみつかりません! - + C/C++ Source C/C++のソースコード - + Compile database コンパイルデータベース - + Visual Studio Visual Studio - + Borland C++ Builder 6 Borland C++ Builder 6 - + Select files to analyze チェック対象のファイルを選択 - + Select directory to analyze チェックするディレクトリを選択してください - + Select the configuration that will be analyzed チェックの設定を選択 - + Found project files from the directory. Do you want to proceed analysis without using any of these project files? @@ -1169,7 +1376,7 @@ Do you want to proceed analysis without using any of these project files? - + Current results will be cleared. Opening a new XML file will clear current results. @@ -1179,7 +1386,7 @@ Do you want to proceed? 新しくXMLファイルを開くと現在の結果が削除されます。実行しますか? - + Analyzer is running. Do you want to stop the analysis and exit Cppcheck? @@ -1188,47 +1395,47 @@ Do you want to stop the analysis and exit Cppcheck? チェックを中断して、Cppcheckを終了しますか? - + About - CppCheckについて + - + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) XML ファイル (*.xml);;テキストファイル (*.txt);;CSVファイル (*.csv) - + Build dir '%1' does not exist, create it? ビルドディレクトリ'%1'がありません。作成しますか? - + To check the project using addons, you need a build directory. アドオンを使用してプロジェクトをチェックするためには、ビルドディレクトリが必要です。 - + Failed to import '%1', analysis is stopped '%1'のインポートに失敗しました。(チェック中断) - + Project files (*.cppcheck) プロジェクトファイル (*.cppcheck) - + Select Project Filename プロジェクトファイル名を選択 - + No project file loaded プロジェクトファイルが読み込まれていません - + The project file %1 @@ -1321,6 +1528,10 @@ Options: Platforms + + Built-in + ビルトイン + Native @@ -1352,6 +1563,21 @@ Options: Windows 64-bit + + Project + + Cppcheck + Cppcheck + + + Could not read the project file. + プロジェクトファイルが読み込めませんでした + + + Could not write the project file. + プロジェクトファイルが保存できませんでした + + ProjectFile @@ -1359,6 +1585,10 @@ Options: Project File プロジェクトファイル + + Project + プロジェクト + Paths and Defines @@ -1376,11 +1606,24 @@ Options: Defines must be separated by a semicolon ';' 定義(Define)はセミコロン';'で区切る必要があります。 例: DEF1;DEF2=5;DEF3=int + + &Root: + Root: + ルート: + + + Libraries: + ライブラリ + Note: Put your own custom .cfg files in the same folder as the project file. You should see them above. カスタマイズした cfgファイルを同じフォルダにプロジェクトファイルとして保存してください。ここに表示できるようになります。 + + Exclude paths + 除外するパス + MISRA C 2012 @@ -1514,6 +1757,18 @@ Options: Exclude file... ファイルで除外... + + Clang + Clang + + + Check that code is safe + コードの安全性確認 + + + Bug hunting -- Detect all bugs. Generates mostly noise. + バグハント -- 全てのバグを検出。ノイズになりがち。 + Check that each class has a safe public interface @@ -1524,6 +1779,10 @@ Options: Limit analysis 解析の制限 + + Check code in headers (slower analysis, more results) + ヘッダファイルのコードもチェック(解析に時間がかかりますが結果は増えます) + Check code in unused templates (should be ON normally, however in theory you can safely ignore warnings in unused templates) @@ -1535,11 +1794,27 @@ Options: Max CTU depth CTUの最大深さ + + Exclude source files in paths + 除外するソースファイルのPATH + + + Note: Addons require <a href="https://www.python.org/">Python</a> beeing installed. + 注意: アドオンには<a href="https://www.python.org/">Python</a> が必要です。 + External tools 外部ツール + + Includes + インクルード + + + Include directories: + インクルードディレクトリ: + Up @@ -1550,6 +1825,10 @@ Options: Down + + Checking + チェック + Platform @@ -1560,6 +1839,14 @@ Options: Clang (experimental) Clang (実験的) + + Normal analysis -- Avoid false positives. + 通常解析--偽陽性を避ける。 + + + Bug hunting -- Generates mostly noise. The goal is to be "soundy" and detect most bugs. + バグハンティング-- 不必要な指摘を含む。これはノイズが多くても全てのバグを検出する目的で使用します。 + If you want to design your classes to be as flexible and robust as possible then the public interface must be very robust. Cppcheck will asumme that arguments can take *any* value. @@ -1600,16 +1887,28 @@ Options: Libraries ライブラリ + + Exclude + 除外する + Suppressions 指摘の抑制 + + Suppression list: + 抑制リスト + Add 追加 + + Addons and tools + アドオンとツール + @@ -1636,6 +1935,18 @@ Options: Coding standards コーディング標準 + + CERT + CERT + + + Extra Tools + エクストラツール + + + It is common best practice to use several tools. + 複数ツールの併用はよい結果を生みます。 + Clang analyzer @@ -1660,81 +1971,111 @@ Options: プロジェクトファイル:%1 - + Select Cppcheck build dir Cppcheckビルドディレクトリ - + Visual Studio (*.sln *.vcxproj);;Compile database (compile_commands.json) + Visual Studio (*.sln *.vcxproj);;コンパイルデータベース (compile_commands.json) + + + Select include directory includeディレクトリを選択 - + Select a directory to check チェックするディレクトリを選択してください - (no rule texts file) - (ルールテキストファイルがない) + (ルールテキストファイルがない) - + Clang-tidy (not found) Clang-tidy (みつかりません) - + Visual Studio Visual Studio - + Compile database コンパイルデータベース - + Borland C++ Builder 6 Borland C++ Builder 6 - + Import Project プロジェクトのインポート - + Select directory to ignore 除外するディレクトリを選択してください - + Source files ソースファイル - + All files 全ファイル - + Exclude file 除外ファイル - + Add Suppression + 抑制する指摘を追加 + + + Select error id suppress: + 抑制するエラーID(error id)を選択してください + + + Select MISRA rule texts file MISRAルールテキストファイルを選択 - + MISRA rule texts file (%1) MISRAルールテキストファイル (%1) + + QDialogButtonBox + + OK + OK + + + Cancel + キャンセル + + + Close + 閉じる + + + Save + 保存する + + QObject @@ -1979,6 +2320,10 @@ Options: Please select the directory where file is located. ファイルのあるディレクトリを選択してください。 + + [Inconclusive] + [結論の出ない] + debug @@ -1994,6 +2339,22 @@ Options: Recheck 再チェック + + Copy filename + ファイル名をコピー + + + Copy full path + フルパスをコピー + + + Copy message + メッセージをコピー + + + Copy message id + メッセージidをコピー + Hide @@ -2014,6 +2375,14 @@ Options: Open containing folder 含まれるフォルダを開く + + Edit contract.. + 関数の構成を編集。 + + + Suppress + 抑制 + @@ -2063,6 +2432,14 @@ Please check the application path and parameters are correct. %1 が実行できません。 実行ファイルパスや引数の設定を確認してください。 + + + Could not find file: +%1 +Please select the directory where file is located. + ファイルが見つかりません: +%1 +ディレクトリにファイルが存在するか確認してください。 @@ -2132,6 +2509,34 @@ Please check the application path and parameters are correct. Warning Details 警告の詳細 + + Functions + 関数 + + + Variables + 変数 + + + Only show variable names that contain text: + 指定テキストを含む変数名のみ表示: + + + Contracts + 構成 + + + Configured contracts: + 設定した構成: + + + Missing contracts: + 構成なし: + + + No errors found, nothing to save. + 警告/エラーが見つからなかったため、保存しません。 + @@ -2181,6 +2586,14 @@ To toggle what kind of errors are shown, open view menu. XML format version 1 is no longer supported. XML フォーマットバージョン 1 はもうサポートされていません。 + + Summary + 内容 + + + Message + メッセージ + First included by @@ -2252,6 +2665,10 @@ To toggle what kind of errors are shown, open view menu. General 全般 + + Include paths: + Include ディレクトリ: + Add... @@ -2390,6 +2807,14 @@ To toggle what kind of errors are shown, open view menu. Custom カスタム + + Paths + パス + + + Edit + 編集 + Remove @@ -2431,6 +2856,14 @@ To toggle what kind of errors are shown, open view menu. Language 言語 + + Advanced + 高度 + + + &Show inconclusive errors + 結論の出ないのエラーを表示 + SettingsDialog @@ -2479,6 +2912,10 @@ To toggle what kind of errors are shown, open view menu. Select clang path clangのパスの選択 + + Select include directory + include ディレクトリを選択 + StatsDialog @@ -2769,6 +3206,25 @@ The user interface language has been reset to English. Open the Preferences-dial 結論の出ない + + VariableContractsDialog + + Dialog + ダイアログ + + + You can specify min and max value for the variable here + ここで変数の最小値と最大値を指定します。 + + + Min + 最小値 + + + Max + 最大値 + + toFilterString diff --git a/gui/cppcheck_ko.ts b/gui/cppcheck_ko.ts index 869f373a1..9c67fa22f 100644 --- a/gui/cppcheck_ko.ts +++ b/gui/cppcheck_ko.ts @@ -109,6 +109,10 @@ Kate로 파일을 열고, 해당 행으로 이동하는 예제: Cppcheck Cppcheck + + You must specify a name, a path and parameters for the application! + 응용 프로그램의 이름, 경로 및 인자를 명시해야 합니다! + You must specify a name, a path and optionally parameters for the application! @@ -416,23 +420,50 @@ Kate로 파일을 열고, 해당 행으로 이동하는 예제: + + LogView + + Checking Log + 로그 확인 + + + Clear + 지우기 + + + Save Log + 로그 저장 + + + Text files (*.txt *.log);;All files (*.*) + 텍스트 파일 (*.txt *.log);;모든 파일 (*.*) + + + Cppcheck + Cppcheck + + + Could not open file for writing: "%1" + 기록할 파일 열기 실패: "%1" + + MainWindow - - - - - - - - - - - - - + + + + + + + + + + + + + Cppcheck Cppcheck @@ -457,288 +488,344 @@ Kate로 파일을 열고, 해당 행으로 이동하는 예제: 도움말(&H) - + &Check + 검사(&C) + + + &Edit 편집(&E) - + Standard 표준 도구 - + Categories 분류 도구 - + Filter 필터 도구 - + &License... 저작권(&L)... - + A&uthors... 제작자(&u)... - + &About... 정보(&A)... - + &Files... 파일(&F)... - + Check files + 파일 검사 + + + Ctrl+F Ctrl+F - + &Directory... 디렉토리(&D)... - + Check directory + 디렉토리 검사 + + + Ctrl+D Ctrl+D - + &Recheck files + 파일 재검사(&R) + + + Ctrl+R Ctrl+R - + &Stop 중지(&S) - + Stop checking + 검사 중지 + + + Esc Esc - + &Save results to file... 결과를 파일에 저장(&S)... - + Ctrl+S Ctrl+S - + &Quit 종료(&Q) - + &Clear results 결과 지우기(&C) - + &Preferences 설정(&P) - - + Style warnings + 스타일 경고 + + + + Show style warnings 스타일 경고 표시 - - + Errors + 에러 + + + + Show errors 애러 표시 - + &Check all 전체 선택(&C) - + &Uncheck all 전체 해제(&U) - + Collapse &all 전체 접기(&A) - + &Expand all 전체 펼치기(&E) - + &Standard 표준 도구(&S) - + Standard items 표준 아이템 - + &Contents 내용(&C) - + Open the help contents 도움말을 엽니다 - + F1 F1 - + Toolbar 도구바 - + &Categories 분류 도구(&C) - + Error categories 에러 종류 - + &Open XML... XML 열기(&O)... - + Open P&roject File... 프로젝트 파일 열기(&R)... - + &New Project File... 새 프로젝트 파일(&N)... - + &Log View 로그 보기(&L) - + Log View 로그 보기 - + C&lose Project File 프로젝트 파일 닫기(&L) - + &Edit Project File... 프로젝트 파일 편집(&E)... - + &Statistics 통계 보기(&S) - - + Warnings + 경고 + + + + Show warnings 경고 표시 - - + Performance warnings + 성능 경고 + + + + Show performance warnings 성능 경고 표시 - + Show &hidden 숨기기 보기(&H) - - + + Information 정보 - + Show information messages 정보 표시 - + Portability + 이식성 경고 + + + Show portability warnings 이식성 경고 표시 - + &Filter 필터 도구(&F) - + Filter results 필터링 결과 - + Windows 32-bit ANSI Windows 32-bit ANSI - + Windows 32-bit Unicode Windows 32-bit Unicode - + Unix 32-bit Unix 32-bit - + Unix 64-bit Unix 64-bit - + Windows 64-bit Windows 64-bit + + Platforms + 플랫폼 + + + C++11 + C++11 + + + C99 + C99 + + + Posix + Posix + - + Quick Filter: 빠른 필터: - + There was a problem with loading the editor application settings. This is probably because the settings were changed between the Cppcheck versions. Please check (and fix) the editor application settings, otherwise the editor program might not start correctly. @@ -747,12 +834,20 @@ This is probably because the settings were changed between the Cppcheck versions Cppcheck 버전간 설정 방법 차이때문인 것으로 보입니다. 편집기 설정을 검사(및 수정)해주세요, 그렇지 않으면 편집기가 제대로 시작하지 않습니다. - + No suitable files found to check! + 검사할 수 있는 파일이 없습니다! + + + You must close the project file before selecting new files or directories! 새로운 파일이나 디렉토리를 선택하기 전에 프로젝트 파일을 닫으세요! - + Select directory to check + 검사할 디렉토리 선택 + + + Found project file: %1 Do you want to load this project file instead? @@ -761,81 +856,125 @@ Do you want to load this project file instead? 이 프로젝트 파일을 불러오겠습니까? - - + Found project files from the directory. + +Do you want to proceed checking without using any of these project files? + 디렉토리에 프로젝트 파일 존재. + +이 프로젝트 파일을 사용하지 않고 검사를 계속하시겠습니까? + + + + XML files (*.xml) XML 파일 (*.xml) - + Open the report file 보고서 파일 열기 - + Checking is running. + +Do you want to stop the checking and exit Cppcheck? + 검사 중. + +검사를 중지하고 Cppcheck을 종료하시겠습니까? + + + License 저작권 - + Authors 제작자 - + XML files version 2 (*.xml);;XML files version 1 (*.xml);;Text files (*.txt);;CSV files (*.csv) + XML 파일 버전 2 (*.xml);;XML 파일 버전 1 (*.xml);;텍스트 파일 (*.txt);;CSV 파일 (*.csv) + + + Save the report file 보고서 파일 저장 - + XML files version 1 (*.xml) + XML 파일 버전 1 (*.xml) + + + XML files version 2 (*.xml) + XML 파일 버전 2 (*.xml) + + + Text files (*.txt) 텍스트 파일 (*.txt) - + CSV files (*.csv) CSV 파일 (*.csv) - + Cppcheck - %1 + Cppcheck - %1 + + + Failed to change the user interface language: + +%1 + +The user interface language has been reset to English. Open the Preferences-dialog to select any of the available languages. + 언어 변경 실패: + +%1 + +언어가 영어로 초기화 됐습니다. 설정창을 열어서 설정 가능한 언어를 선택하세요. + + + Project files (*.cppcheck);;All files(*.*) 프로젝트 파일 (*.cppcheck);;모든 파일(*.*) - + Select Project File 프로젝트 파일 선택 - - - + + + Project: 프로젝트: - + About - + To check the project using addons, you need a build directory. - + Select Project Filename 프로젝트 파일이름 선택 - + No project file loaded 프로젝트 파일 불러오기 실패 - + The project file %1 @@ -851,6 +990,10 @@ Do you want to remove the file from the recently used projects -list? 최근 프로젝트 목록에서 파일을 제거하시겠습니까? + + Select files to check + 검사할 파일 선택 + Cppcheck GUI - Command line parameters @@ -862,94 +1005,106 @@ Do you want to remove the file from the recently used projects -list? - + C11 + C11 + + + C89 + C89 + + + C++03 + C++03 + + + Error - + File not found - + Bad XML - + Missing attribute - + Bad attribute value - + Failed to load the selected library '%1'. %2 - + Unsupported format - + The library '%1' contains unknown elements: %2 - + Duplicate platform type - + Platform type redefined - + &Print... - + Print the Current Report - + Print Pre&view... - + Open a Print Preview Dialog for the Current Results - + Open library editor - + Unknown element - + Unknown issue - + Select configuration @@ -972,72 +1127,72 @@ Options: - + Failed to load %1. Your Cppcheck installation is broken. You can use --data-dir=<directory> at the command line to specify where this file is located. Please note that --data-dir is supposed to be used by installation scripts and therefore the GUI does not start when it is used, all that happens is that the setting is configured. - + Build dir '%1' does not exist, create it? - - + + Analyze files - - + + Analyze directory - + &Reanalyze modified files - - + + Stop analysis - + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) - + No suitable files found to analyze! - + Select files to analyze - + Select directory to analyze - + Select the configuration that will be analyzed - + Found project files from the directory. Do you want to proceed analysis without using any of these project files? - + Analyzer is running. Do you want to stop the analysis and exit Cppcheck? @@ -1049,192 +1204,192 @@ Do you want to stop the analysis and exit Cppcheck? - + &C standard - + Reanal&yze all files - + Ctrl+Q - + Style war&nings - + E&rrors - + Ctrl+Shift+O - + Sh&ow Scratchpad... - + Ctrl+Shift+N - + &Warnings - + Per&formance warnings - + &Information - + &Portability - + Show Cppcheck results - + Clang - + Show Clang results - + P&latforms - + C++&11 - + C&99 - + &Posix - + C&11 - + &C89 - + &C++03 - + &Library Editor... - + &Auto-detect language - + &Enforce C++ - + E&nforce C - + C++14 C++14 - + Failed to import '%1', analysis is stopped - + Project files (*.cppcheck) - + Reanalyze and check library - + Check configuration (defines, includes) - + C++17 C++17 - + C++20 C++20 - + C/C++ Source - + Compile database - + Visual Studio - + Borland C++ Builder 6 - + Current results will be cleared. Opening a new XML file will clear current results. @@ -1302,12 +1457,31 @@ Do you want to proceed? Windows 64-bit Windows 64-bit + + Built-in + 내장 방식 + Native + + Project + + Cppcheck + Cppcheck + + + Could not read the project file. + 프로젝트 파일을 읽을 수 없습니다. + + + Could not write the project file. + 프로젝트 파일에 쓸 수 없습니다. + + ProjectFile @@ -1315,11 +1489,19 @@ Do you want to proceed? Project File 프로젝트 파일 + + Project + 프로젝트 + Defines: Defines: + + Root: + Root: + Paths: @@ -1346,6 +1528,14 @@ Do you want to proceed? Remove 제거 + + Includes + Includes + + + Include directories: + Include 디렉토리: + Up @@ -1356,6 +1546,10 @@ Do you want to proceed? Down 아래로 + + Exclude + Exclude + Suppressions @@ -1614,81 +1808,83 @@ Do you want to proceed? 프로젝트 파일: %1 - + Select include directory Include 디렉토리 선택 - + Select a directory to check 검사할 디렉토리 선택 - + Select directory to ignore 무시할 디렉토리 선택 - + Select Cppcheck build dir - + Import Project - + Clang-tidy (not found) - - (no rule texts file) - - - - + Source files - + All files - + Exclude file - + Select MISRA rule texts file - + MISRA rule texts file (%1) - + Visual Studio - + Compile database - + Borland C++ Builder 6 + + QDialogButtonBox + + Close + 닫기 + + QObject @@ -1907,6 +2103,10 @@ Do you want to proceed? Undefined file 미정의된 파일 + + [Inconclusive] + [불확실] + style @@ -1942,6 +2142,18 @@ Do you want to proceed? debug 디버그 + + Copy filename + 파일이름 복사 + + + Copy full path + 전체 경로 복사 + + + Copy message + 메시지 복사 + Hide @@ -1984,6 +2196,14 @@ Please check the application path and parameters are correct. %1을 시잘할 수 없습니다 경로와 인자가 정확한지 확인하세요. + + + Could not find file: +%1 +Please select the directory where file is located. + 파일 찾기 실패: +%1 +파일이 위치한 디렉토리를 선택하세요. @@ -2074,6 +2294,10 @@ Please check the application path and parameters are correct. Results 결과 + + No errors found, nothing to save. + 에러가 발견되지 않았고, 저장할 내용이 없습니다. + @@ -2114,6 +2338,14 @@ To toggle what kind of errors are shown, open view menu. Bug hunting analysis is incomplete + + Summary + 요약 + + + Message + 내용 + Id @@ -2235,11 +2467,23 @@ To toggle what kind of errors are shown, open view menu. Enable inline suppressions Inline suppression 사용 + + Paths + 경로 + + + Include paths: + Include 경로: + Add... 추가... + + Edit + 편집 + Remove @@ -2281,6 +2525,18 @@ To toggle what kind of errors are shown, open view menu. Language 언어 + + Advanced + 고급 + + + &Show inconclusive errors + 불확실한 에러 표시(&S) + + + S&how internal warnings in log + 로그에 내부 경고 표시(&H) + Display error Id in column "Id" @@ -2411,6 +2667,10 @@ To toggle what kind of errors are shown, open view menu. [Default] [기본] + + Select include directory + Include 디렉토리 선택 + [Default] diff --git a/gui/cppcheck_nl.ts b/gui/cppcheck_nl.ts index badbebddf..8037fe30d 100644 --- a/gui/cppcheck_nl.ts +++ b/gui/cppcheck_nl.ts @@ -420,23 +420,50 @@ Parameters: -l(lijn) (bestand) + + LogView + + Checking Log + Controleer log + + + Clear + Wis + + + Save Log + Opslaan log + + + Text files (*.txt *.log);;All files (*.*) + Tekst bestanden (*.txt *.log);;Alle bestanden(*.*) + + + Cppcheck + Cppcheck + + + Could not open file for writing: "%1" + Kan bestand: "%1" niet openen om te schrijven + + MainWindow - - - - - - - - - - - - - + + + + + + + + + + + + + Cppcheck Cppcheck @@ -446,7 +473,7 @@ Parameters: -l(lijn) (bestand) - + Standard Standaard @@ -465,486 +492,518 @@ Parameters: -l(lijn) (bestand) &Toolbars &Werkbalken + + &Check + &Controleer + C++ standard C++standaard - + &C standard C standard C standaard - + &Edit Be&werken - + &License... &Licentie... - + A&uthors... A&uteurs... - + &About... &Over... - + &Files... &Bestanden... - - + + Analyze files Check files Controleer bestanden - + Ctrl+F Ctrl+F - + &Directory... &Mappen... - - + + Analyze directory Check directory Controleer Map - + Ctrl+D Ctrl+D - + &Recheck files + &Opnieuw controleren + + + Ctrl+R Ctrl+R - + &Stop &Stop - - + + Stop analysis Stop checking Stop controle - + Esc Esc - + &Save results to file... &Resultaten opslaan... - + Ctrl+S Ctrl+S - + &Quit &Afsluiten - + &Clear results &Resultaten wissen - + &Preferences &Voorkeuren - - + Errors + Fouten + + + + Show errors Toon fouten - - + Show S&cratchpad... + Toon S&cratchpad... + + + Warnings + Waarschuwingen + + + + Show warnings Toon waarschuwingen - - + Performance warnings + Presentatie waarschuwingen + + + + Show performance warnings Toon presentatie waarschuwingen - + Show &hidden Toon &verborgen - - + + Information Informatie - + Show information messages Toon informatie bericht - + Portability + Portabiliteit + + + Show portability warnings Toon portabiliteit waarschuwingen - + Show Cppcheck results - + Clang - + Show Clang results - + &Filter &Filter - + Filter results Filter resultaten - + Windows 32-bit ANSI Windows 32-bit ANSI - + Windows 32-bit Unicode - + Unix 32-bit - + Unix 64-bit - + Windows 64-bit - + &Print... - + Print the Current Report - + Print Pre&view... - + Open a Print Preview Dialog for the Current Results - + Open library editor - + &Check all &Controleer alles - + Filter - + &Reanalyze modified files &Recheck modified files - + Reanal&yze all files - + Ctrl+Q - + Style war&nings - + E&rrors - + &Uncheck all Selecteer &niets - + Collapse &all Alles Inkl&appen - + &Expand all Alles &Uitklappen - + &Standard &Standaard - + Standard items Standaard items - + Toolbar Werkbalk - + &Categories &Categorieën - + Error categories Foute Categorieën - + &Open XML... - + Open P&roject File... Open P&oject bestand... - + Ctrl+Shift+O - + Sh&ow Scratchpad... - + &New Project File... &Nieuw Project Bestand... - + Ctrl+Shift+N - + &Log View &Log weergave - + Log View Log weergave - + C&lose Project File &Sluit Project Bestand - + &Edit Project File... &Bewerk Project Bestand... - + &Statistics &Statistieken - + &Warnings - + Per&formance warnings - + &Information - + &Portability - + P&latforms - + C++&11 - + C&99 - + &Posix - + C&11 - + &C89 - + &C++03 - + &Library Editor... - + &Auto-detect language - + &Enforce C++ - + E&nforce C - + C++14 - + Reanalyze and check library - + Check configuration (defines, includes) - + C++17 - + C++20 - + &Contents &Inhoud - + Categories Categorieën - - + Style warnings + Stijl waarschuwingen + + + + Show style warnings Toon stijl waarschuwingen - + Open the help contents Open de help inhoud - + F1 @@ -953,19 +1012,27 @@ Parameters: -l(lijn) (bestand) &Help &Help + + Select directory to check + Selecteer een map om te controleren + + + No suitable files found to check! + Geen geschikte bestanden gevonden om te controleren! + - + Quick Filter: Snel Filter: - + Select configuration - + Found project file: %1 Do you want to load this project file instead? @@ -973,54 +1040,66 @@ Do you want to load this project file instead? Wilt u dit project laden in plaats van? - + Found project files from the directory. + +Do you want to proceed checking without using any of these project files? + Project bestanden gevonden in de map. +Wil je verder wilt gaan zonder controle van deze project bestanden? + + + File not found - + Bad XML - + Missing attribute - + Bad attribute value - + Failed to load the selected library '%1'. %2 - + License Licentie - + Authors Auteurs - + XML files version 2 (*.xml);;XML files version 1 (*.xml);;Text files (*.txt);;CSV files (*.csv) + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) + XML bestanden (*.xml);;Tekst bestanden (*.txt);;CSV bestanden (*.csv) + + + Save the report file Rapport opslaan - - + + XML files (*.xml) XML bestanden (*.xml) - + There was a problem with loading the editor application settings. This is probably because the settings were changed between the Cppcheck versions. Please check (and fix) the editor application settings, otherwise the editor program might not start correctly. @@ -1029,133 +1108,165 @@ This is probably because the settings were changed between the Cppcheck versions Dit is waarschijnlijk omdat de instellingen zijn gewijzigd tussen de versies van cppcheck. Controleer (en maak) de bewerker instellingen, anders zal de bewerker niet correct starten. - + You must close the project file before selecting new files or directories! Je moet project bestanden sluiten voordat je nieuwe bestanden of mappen selekteerd! - + Select files to check + Selecteer bestanden om te controleren + + + The library '%1' contains unknown elements: %2 - + Unsupported format - + Duplicate platform type - + Platform type redefined - + Unknown element - + Unknown issue - + Error - + Failed to load %1. Your Cppcheck installation is broken. You can use --data-dir=<directory> at the command line to specify where this file is located. Please note that --data-dir is supposed to be used by installation scripts and therefore the GUI does not start when it is used, all that happens is that the setting is configured. - + Current results will be cleared. + +Opening a new XML file will clear current results.Do you want to proceed? + Huidige resultaten zullen worden gewist + +Een nieuw XML-bestand openen zal de huidige resultaten wissen Wilt u verder gaan? + + + Open the report file Open het rapport bestand - + Checking is running. + +Do you want to stop the checking and exit Cppcheck? + Het controleren loopt. + +Wil je het controleren stoppen en Cppcheck sluiten? + + + XML files version 1 (*.xml) + XML files version 1 (*.xml) + + + XML files version 2 (*.xml) + XML files version 2 (*.xml) + + + Text files (*.txt) Tekst bestanden (*.txt) - + CSV files (*.csv) CSV bestanden (*.csv) - + Cppcheck - %1 + Cppcheck - %1 + + + Project files (*.cppcheck);;All files(*.*) Project bestanden (*.cppcheck);;Alle bestanden(*.*) - + Select Project File Selecteer project bestand - - - + + + Project: Project: - + No suitable files found to analyze! - + C/C++ Source - + Compile database - + Visual Studio - + Borland C++ Builder 6 - + Select files to analyze - + Select directory to analyze - + Select the configuration that will be analyzed - + Found project files from the directory. Do you want to proceed analysis without using any of these project files? - + Current results will be cleared. Opening a new XML file will clear current results. @@ -1163,54 +1274,54 @@ Do you want to proceed? - + Analyzer is running. Do you want to stop the analysis and exit Cppcheck? - + About - + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) - + Build dir '%1' does not exist, create it? - + To check the project using addons, you need a build directory. - + Failed to import '%1', analysis is stopped - + Project files (*.cppcheck) - + Select Project Filename Selecteer project bestandsnaam - + No project file loaded Geen project bestand geladen - + The project file %1 @@ -1224,6 +1335,29 @@ Do you want to remove the file from the recently used projects -list? Kan niet worden gevonden! Wilt u het bestand van de onlangs gebruikte project verwijderen -lijst? + + + Cppcheck GUI. + +Syntax: + cppcheck-gui [OPTIONS] [files or paths] + +Options: + -h, --help Print this help + -p <file> Open given project file and start checking it + -l <file> Open given results xml file + -d <directory> Specify the directory that was checked to generate the results xml specified with -l + -v, --version Show program version + Cppcheck GUI. +Syntax: +....cppcheck-gui [Opies] [bestanden of paden] + +Opties: +.....-h, --help Print deze help +.....-p <bestand>......Open project bestand en start de controle +.....-l <bestand>......Open gegeven resultaten xml bestand +.....-d <map> Geef de map aan wat gecontroleerd werd om de xml resultaten te genereren met gespecificeerde -l +.....-v,.--versie Toon versie van programma @@ -1296,6 +1430,10 @@ Options: Platforms + + Built-in + Gemaakt in + Native @@ -1327,6 +1465,21 @@ Options: + + Project + + Cppcheck + Cppcheck + + + Could not read the project file. + Kon project bestand niet lezen. + + + Could not write the project file. + Kon niet naar project bestand schrijven. + + ProjectFile @@ -1334,6 +1487,10 @@ Options: Project File Project Bestand + + Project + Project + Paths and Defines @@ -1351,6 +1508,11 @@ Options: Defines must be separated by a semicolon ';' + + &Root: + Root: + Hoofdmap: + Note: Put your own custom .cfg files in the same folder as the project file. You should see them above. @@ -1510,6 +1672,14 @@ Options: External tools + + Includes + Inclusief + + + Include directories: + Include mappen: + Up @@ -1575,6 +1745,10 @@ Options: Libraries + + Exclude + Exclusief + Suppressions @@ -1635,81 +1809,91 @@ Options: Project Bestand %1 - + Select Cppcheck build dir - + Select include directory Selecteer include map - + Select a directory to check Selecteer een map om te controleren - - (no rule texts file) - - - - + Clang-tidy (not found) - + Visual Studio - + Compile database - + Borland C++ Builder 6 - + Import Project - + Select directory to ignore Selecteer een map om te negeren - + Source files - + All files - + Exclude file - + Select MISRA rule texts file - + MISRA rule texts file (%1) + + QDialogButtonBox + + Cancel + Annuleer + + + Close + Sluit + + + Save + Opslaan + + QObject @@ -1956,6 +2140,10 @@ Options: Please select the directory where file is located. + + [Inconclusive] + [Onduidelijk] + debug @@ -1971,6 +2159,22 @@ Options: Recheck + + Copy filename + Kopier bestandsnaam + + + Copy full path + Kopieer volledig pad + + + Copy message + Kopieer bericht + + + Copy message id + Kopieer bericht id + Hide @@ -2039,6 +2243,13 @@ Please check the application path and parameters are correct. Kon applicatie %1 niet starten Gelieve te controleren of de het pad en de parameters correct zijn. + + + Could not find file: +%1 +Please select the directory where file is located. + %1 +Selecteer de map waarin het bestand zich bevindt. @@ -2137,6 +2348,14 @@ Gebruik het uitzicht menu om te selecteren welke fouten getoond worden.XML format version 1 is no longer supported. + + Summary + Overzicht + + + Message + Bericht + First included by @@ -2167,6 +2386,10 @@ Gebruik het uitzicht menu om te selecteren welke fouten getoond worden.Copy complete Log + + No errors found, nothing to save. + Geen fouten gevonden; geen data om op te slaan. + @@ -2229,6 +2452,10 @@ Gebruik het uitzicht menu om te selecteren welke fouten getoond worden.General Algemeen + + Include paths: + Include paden: + Add... @@ -2367,6 +2594,14 @@ Gebruik het uitzicht menu om te selecteren welke fouten getoond worden.Custom + + Paths + Paden + + + Edit + Bewerk + Remove @@ -2408,6 +2643,18 @@ Gebruik het uitzicht menu om te selecteren welke fouten getoond worden.Language Taal + + Advanced + Geavanceerd + + + &Show inconclusive errors + &Toon onduidelijke fouten + + + S&how internal warnings in log + T&oon interne waarschuwingen in log + SettingsDialog @@ -2456,6 +2703,10 @@ Gebruik het uitzicht menu om te selecteren welke fouten getoond worden.Select clang path + + Select include directory + Selecteer include map + StatsDialog diff --git a/gui/cppcheck_ru.ts b/gui/cppcheck_ru.ts index d4f20bde6..5bd1ff1a9 100644 --- a/gui/cppcheck_ru.ts +++ b/gui/cppcheck_ru.ts @@ -41,6 +41,27 @@ of the GNU General Public License version 3 <html><head/><body><p>Many thanks to these libraries that we use:</p><ul style="margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; -qt-list-indent: 1;"><li style=" margin-top:12px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">pcre</li><li style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">picojson</li><li style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">qt</li><li style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">tinyxml2</li></ul></body></html> + + <html><head/><body> +<p>Many thanks to these libraries that we use:</p><ul> +<li>pcre</li> +<li>picojson</li> +<li>qt</li> +<li>tinyxml2</li> +<li>z3</li></ul></body></html> + <html><head/><body> +<p>Many thanks to these libraries that we use:</p><ul> +<li>tinyxml2</li> +<li>picojson</li> +<li>pcre</li> +<li>qt</li></ul></body></html> + <html><head/><body> +<p>Создано при использовании библиотек:</p><ul> +<li>tinyxml2</li> +<li>picojson</li> +<li>pcre</li> +<li>qt</li></ul></body></html> + ApplicationDialog @@ -420,23 +441,50 @@ Parameters: -l(line) (file) + + LogView + + Checking Log + Лог проверки + + + Clear + Очистить + + + Save Log + Сохранить + + + Text files (*.txt *.log);;All files (*.*) + Текстовые файлы (*.txt *.log);;Все файлы (*.*) + + + Cppcheck + Cppcheck + + + Could not open file for writing: "%1" + Не удалось записать в файл: "%1" + + MainWindow - - - - - - - - - - - - - + + + + + + + + + + + + + Cppcheck Cppcheck @@ -446,7 +494,7 @@ Parameters: -l(line) (file) Анализ - + Standard Стандартные @@ -465,486 +513,567 @@ Parameters: -l(line) (file) &Toolbars &Панель инструментов + + &Check + &Проверить + C++ standard Стандарт C++ - + &C standard C standard &Стандарт C - + &Edit &Правка - + &License... &Лицензия... - + A&uthors... &Авторы... - + &About... &О программе... - + &Files... &Файлы... - - + + Analyze files Check files Проверить файлы - + Ctrl+F Ctrl+F - + &Directory... &Каталог... - - + + Analyze directory Check directory Проверка каталога - + Ctrl+D Ctrl+D - + &Recheck files + &Перепроверить файлы + + + Ctrl+R Ctrl+R - + &Reanalyze all files + &Recheck all files + Заново проверить все файлы + + + &Stop Остановить - - + + Stop analysis Stop checking Остановить проверку - + Esc Esc - + &Save results to file... Сохранить отчёт в файл... - + Ctrl+S Ctrl+S - + &Quit Выход - + &Clear results Очистить отчёт - + &Preferences Параметры - - + Errors + Ошибки + + + + Show errors Показать ошибки - - + Show S&cratchpad... + Показать блокнот + + + Warnings + Предупреждения + + + + Show warnings Показать предупреждения - - + Performance warnings + Предупреждения производительности + + + + Show performance warnings Показать предупреждения производительности - + Show &hidden Показать скрытые - - + + Information Информационные сообщения - + Show information messages Показать информационные сообщения - + Portability + Переносимость + + + Show portability warnings Показать предупреждения переносимости - + Show Cppcheck results Просмотр результатов Cppcheck - + Clang Clang - + Show Clang results Просмотр результатов Clang - + &Filter Фильтр - + Filter results Результаты фильтрации - + Windows 32-bit ANSI Windows 32-bit ANSI - + Windows 32-bit Unicode Windows 32-bit Unicode - + Unix 32-bit Unix 32-bit - + Unix 64-bit Unix 64-bit - + Windows 64-bit Windows 64-bit - + Platforms + Платформы + + + C++11 + C++11 + + + C99 + C99 + + + Posix + Posix + + + C11 + C11 + + + C89 + C89 + + + C++03 + C++03 + + + &Print... Печать... - + Print the Current Report Напечатать текущий отчет - + Print Pre&view... Предварительный просмотр... - + Open a Print Preview Dialog for the Current Results Открыть диалог печати для текущих результатов - + Library Editor... + Редактор библиотек... + + + Open library editor Открыть редактор библиотек - + Auto-detect language + Автоопределение языка + + + Enforce C++ + Принудительно C++ + + + Enforce C + Принудительно C + + + &Check all Отметить все - + Filter Фильтр - + &Reanalyze modified files &Recheck modified files Заново проверить измененные файлы - + Reanal&yze all files Заново проверить все файлы - + Ctrl+Q - + Style war&nings Стилистические предупреждения - + E&rrors Ошибки - + &Uncheck all Сбросить все - + Collapse &all Свернуть все - + &Expand all Развернуть все - + &Standard Стандартные - + Standard items Стандартные элементы - + Toolbar Панель инструментов - + &Categories Категории - + Error categories Категории ошибок - + &Open XML... &Открыть XML... - + Open P&roject File... Открыть файл &проекта... - + Ctrl+Shift+O - + Sh&ow Scratchpad... Показать Блокнот - + &New Project File... &Новый файл проекта... - + Ctrl+Shift+N - + &Log View Посмотреть &лог - + Log View Посмотреть лог - + C&lose Project File &Закрыть файл проекта - + &Edit Project File... &Изменить файл проекта... - + &Statistics &Статистика - + &Warnings Предупреждения - + Per&formance warnings Предупреждения производительности - + &Information Информационные предупреждения - + &Portability Предупреждения переносимости - + P&latforms Платформы - + C++&11 - + C&99 - + &Posix - + C&11 - + &C89 - + &C++03 - + &Library Editor... Редактор библиотеки - + &Auto-detect language Автоматическое определение языка - + &Enforce C++ Принудительно C++ - + E&nforce C Принудительно C - + C++14 C++14 - + Reanalyze and check library Повторный анализ библиотеки - + Check configuration (defines, includes) Проверить конфигурацию (defines, includes) - + C++17 C++17 - + C++20 C++20 - + &Contents Помощь - + Categories Категории - - + Style warnings + Стилистические предупреждения + + + + Show style warnings Показать стилистические предупреждения - + Open the help contents Открыть помощь - + F1 F1 @@ -953,19 +1082,27 @@ Parameters: -l(line) (file) &Help Помощь + + Select directory to check + Выберите каталог для проверки + + + No suitable files found to check! + Не найдено подходящих файлов для проверки! + - + Quick Filter: Быстрый фильтр: - + Select configuration Выбор конфигурации - + Found project file: %1 Do you want to load this project file instead? @@ -974,60 +1111,76 @@ Do you want to load this project file instead? Вы хотите загрузить этот проект? - + Found project files from the directory. + +Do you want to proceed checking without using any of these project files? + Найдены файлы проекта из каталога. +Вы хотите продолжить проверку, не используя ни одного из этих файлов проекта? + + + File not found Файл не найден - + Bad XML Некорректный XML - + Missing attribute Пропущен атрибут - + Bad attribute value Некорректное значение атрибута - + Unsupported format Неподдерживаемый формат - + Failed to load the selected library '%1'. %2 Не удалось загрузить выбранную библиотеку '%1'. %2 - + Failed to load %1. Your Cppcheck installation is broken. You can use --data-dir=<directory> at the command line to specify where this file is located. + Не удалось загрузить %1. Установленный Cppcheck поврежден. Вы можете использовать ключ --data-dir=<directory> в командной строке, чтобы указать, где расположен этот файл. + + + License Лицензия - + Authors Авторы - + XML files version 2 (*.xml);;XML files version 1 (*.xml);;Text files (*.txt);;CSV files (*.csv) + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) + XML файлы версии 2 (*.xml);;XML файлы версии 1 (*.xml);;Текстовые файлы (*.txt);;CSV файлы (*.csv) + + + Save the report file Сохранить файл с отчетом - - + + XML files (*.xml) XML-файлы (*.xml) - + There was a problem with loading the editor application settings. This is probably because the settings were changed between the Cppcheck versions. Please check (and fix) the editor application settings, otherwise the editor program might not start correctly. @@ -1036,122 +1189,166 @@ This is probably because the settings were changed between the Cppcheck versions Возможно, это связано с изменениями в версии программы. Пожалуйста, проверьте (и исправьте) настройки приложения. - + You must close the project file before selecting new files or directories! Вы должны закрыть проект перед выбором новых файлов или каталогов! - + Select files to check + Выберите файлы для проверки + + + The library '%1' contains unknown elements: %2 Библиотека '%1' содержит неизвестные элементы: %2 - + Duplicate platform type Дубликат типа платформы - + Platform type redefined Переобъявление типа платформы - + Unknown element Неизвестный элемент - + Unknown issue Неизвестная проблема - + Error Ошибка - + Failed to load %1. Your Cppcheck installation is broken. You can use --data-dir=<directory> at the command line to specify where this file is located. Please note that --data-dir is supposed to be used by installation scripts and therefore the GUI does not start when it is used, all that happens is that the setting is configured. Невозможно загрузить %1. Cppcheck установлен некорректно. Вы можете использовать --data-dir=<directory> в командной строке для указания расположения файлов конфигурации. Обратите внимание, что --data-dir предназначен для использования сценариями установки. При включении данной опции, графический интерфейс пользователя не запускается. - + Current results will be cleared. + +Opening a new XML file will clear current results.Do you want to proceed? + Текущие результаты будут очищены. + +Открытые нового XML файла приведет к очистке текущих результатов. Продолжить? + + + Open the report file Открыть файл с отчетом - + Checking is running. + +Do you want to stop the checking and exit Cppcheck? + Идет проверка. + +Вы хотите завершить проверку и выйти? + + + XML files version 1 (*.xml) + XML файлы версии 1 (*.xml) + + + XML files version 2 (*.xml) + XML файлы версии 2 (*.xml) + + + Text files (*.txt) Текстовые файлы (*.txt) - + CSV files (*.csv) CSV файлы(*.csv) - + Cppcheck - %1 + Cppcheck - %1 + + + Failed to change the user interface language: + +%1 + +The user interface language has been reset to English. Open the Preferences-dialog to select any of the available languages. + Failed to change the user interface language: + +%1 + +The user interface language has been reset to English. Open the Preferences-dialog to select any of the available languages. + + + Project files (*.cppcheck);;All files(*.*) Файлы проекта (*.cppcheck);;Все файлы(*.*) - + Select Project File Выберите файл проекта - - - + + + Project: Проект: - + No suitable files found to analyze! Не найдено подходящих файлов для анализа - + C/C++ Source Исходный код C/C++ - + Compile database - + Visual Studio Visual Studio - + Borland C++ Builder 6 Borland C++ Builder 6 - + Select files to analyze Выбор файлов для анализа - + Select directory to analyze Выбор каталога для анализа - + Select the configuration that will be analyzed Выбор используемой конфигурации - + Found project files from the directory. Do you want to proceed analysis without using any of these project files? @@ -1160,7 +1357,7 @@ Do you want to proceed analysis without using any of these project files? - + Current results will be cleared. Opening a new XML file will clear current results. @@ -1171,7 +1368,7 @@ Do you want to proceed? Вы хотите продолжить? - + Analyzer is running. Do you want to stop the analysis and exit Cppcheck? @@ -1180,47 +1377,47 @@ Do you want to stop the analysis and exit Cppcheck? Вы хотите остановить анализ и выйти из Cppcheck? - + About - + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) XML файлы (*.xml);;Текстовые файлы (*.txt);;CSV файлы (*.csv) - + Build dir '%1' does not exist, create it? Директория для сборки '%1' не существует, создать? - + To check the project using addons, you need a build directory. - + Failed to import '%1', analysis is stopped Невозможно импортировать '%1', анализ остановлен - + Project files (*.cppcheck) Файлы проекта (*.cppcheck) - + Select Project Filename Выберите имя файла для проекта - + No project file loaded Файл с проектом не загружен - + The project file %1 @@ -1235,6 +1432,30 @@ Do you want to remove the file from the recently used projects -list? не найден! Хотите удалить его из списка проектов? + + Cppcheck GUI. + +Syntax: + cppcheck-gui [OPTIONS] [files or paths] + +Options: + -h, --help Print this help + -p <file> Open given project file and start checking it + -l <file> Open given results xml file + -d <directory> Specify the directory that was checked to generate the results xml specified with -l + -v, --version Show program version + Cppcheck Графический Интерфейс Пользователя . + +Синтаксис: + cppcheck-gui [ОПЦИИ] [файлы или пути] + +Опции: + -h, --help Показать эту справку + -p <file> Откройте данный файл проекта и начните проверять его + -l <file> Откройте данные результаты xml файл + -d <directory> Укажите каталог, который был проверен, чтобы генерировать результаты xml определенный с -l + -v, --version Показать версию программы + Cppcheck GUI. @@ -1319,6 +1540,10 @@ Options: Platforms + + Built-in + Встроенная + Native @@ -1350,6 +1575,21 @@ Options: Windows 64-bit + + Project + + Cppcheck + Cppcheck + + + Could not read the project file. + Не удалось прочитать файл проекта. + + + Could not write the project file. + Не удалось записать файл проекта. + + ProjectFile @@ -1357,6 +1597,10 @@ Options: Project File Файл проекта + + Project + Проект + Paths and Defines @@ -1374,6 +1618,15 @@ Options: Defines must be separated by a semicolon ';' Defines должны быть разделены точкой с запятой ';' + + &Root: + Root: + Корневой каталог: + + + Libraries: + Библиотеки: + Note: Put your own custom .cfg files in the same folder as the project file. You should see them above. @@ -1532,6 +1785,10 @@ Options: Cppcheck (built in) + + Clang + Clang + Check that each class has a safe public interface @@ -1542,6 +1799,10 @@ Options: Limit analysis + + Check code in headers (slower analysis, more results) + Проверить код в заголовочных файлах + Check code in unused templates (should be ON normally, however in theory you can safely ignore warnings in unused templates) @@ -1553,11 +1814,23 @@ Options: Max CTU depth Максимальная глубина CTU + + Exclude source files in paths + Исключить исходные файлы в путях + External tools Внешние инструменты + + Includes + Пути для заголовочных файлов + + + Include directories: + Пути для поиска заголовочных файлов: + Up @@ -1568,6 +1841,10 @@ Options: Down Вниз + + Checking + Проверка + Platform @@ -1598,6 +1875,10 @@ Options: Libraries Библиотеки + + Exclude + Исключенные пути + Suppressions @@ -1608,6 +1889,10 @@ Options: Add Добавить + + Addons and tools + Дополнения + @@ -1634,6 +1919,10 @@ Options: Coding standards Стандарты кодирования + + CERT + CERT + Clang analyzer @@ -1658,81 +1947,99 @@ Options: Файл проекта: %1 - + Select Cppcheck build dir Выбрать директорию сборки Cppcheck - + Select include directory Выберите директорию для поиска заголовочных файлов - + Select a directory to check Выберите директорию для проверки - (no rule texts file) - (файл с текстами правил недоступен) + (файл с текстами правил недоступен) - + Clang-tidy (not found) Clang-tidy (не найден) - + Visual Studio Visual Studio - + Compile database - + Borland C++ Builder 6 Borland C++ Builder 6 - + Import Project Импорт проекта - + Select directory to ignore Выберите директорию, которую надо проигнорировать - + Source files - + All files - + Exclude file - + Select MISRA rule texts file Выбрать файл текстов правил MISRA - + MISRA rule texts file (%1) Файл текстов правил MISRA (%1) + + QDialogButtonBox + + OK + OK + + + Cancel + Отмена + + + Close + Закрыть + + + Save + Сохранить + + QObject @@ -1979,6 +2286,10 @@ Options: Please select the directory where file is located. Укажите каталог с расположением файла. + + [Inconclusive] + [Неубедительный] + debug @@ -1994,6 +2305,22 @@ Options: Recheck Проверить заново + + Copy filename + Скопировать имя файла + + + Copy full path + Скопировать полный путь + + + Copy message + Скопировать сообщение + + + Copy message id + Скопировать номер сообщения + Hide @@ -2060,6 +2387,14 @@ Please select the default editor application in preferences/Applications. Не удалось запустить %1 Пожалуйста, проверьте путь приложения, и верны ли параметры. + + + Could not find file: +%1 +Please select the directory where file is located. + Не удается найти файл: +%1 +Пожалуйста, выберите каталог, в котором находится файл. @@ -2158,6 +2493,14 @@ To toggle what kind of errors are shown, open view menu. XML format version 1 is no longer supported. XML формат версии 1 больше не поддерживается. + + Summary + Кратко + + + Message + Сообщение + First included by @@ -2188,6 +2531,10 @@ To toggle what kind of errors are shown, open view menu. Copy complete Log Скопировать полный лог + + No errors found, nothing to save. + Ошибки не найдены, нечего сохранять. + @@ -2209,6 +2556,10 @@ To toggle what kind of errors are shown, open view menu. Warning Details Детали предупреждения + + Functions + Функции + ScratchPad @@ -2250,6 +2601,10 @@ To toggle what kind of errors are shown, open view menu. General Общие + + Include paths: + Пути для поиска заголовочных файлов: + Add... @@ -2388,6 +2743,14 @@ To toggle what kind of errors are shown, open view menu. Custom + + Paths + Пути + + + Edit + Изменить + Remove @@ -2429,6 +2792,18 @@ To toggle what kind of errors are shown, open view menu. Language Язык + + Advanced + Прочие + + + &Show inconclusive errors + &Показывать незначительные ошибки + + + S&how internal warnings in log + &Записывать внутренние предупреждения в лог + SettingsDialog @@ -2477,6 +2852,10 @@ To toggle what kind of errors are shown, open view menu. Select clang path Выберите исполняемый файл clang + + Select include directory + Выберите директорию + StatsDialog diff --git a/gui/cppcheck_sr.ts b/gui/cppcheck_sr.ts index 3b9e16848..d50b40148 100644 --- a/gui/cppcheck_sr.ts +++ b/gui/cppcheck_sr.ts @@ -408,23 +408,30 @@ Parameters: -l(line) (file) + + LogView + + Cppcheck + Cppcheck + + MainWindow - - - - - - - - - - - - - + + + + + + + + + + + + + Cppcheck Cppcheck @@ -434,7 +441,7 @@ Parameters: -l(line) (file) - + Standard Standard @@ -453,486 +460,522 @@ Parameters: -l(line) (file) &Toolbars + + &Check + &Check + C++ standard - + &C standard C standard - + &Edit &Edit - + &License... &License... - + A&uthors... A&uthors... - + &About... &About... - + &Files... &Files... - - + + Analyze files Check files - + Ctrl+F Ctrl+F - + &Directory... &Directory... - - + + Analyze directory Check directory - + Ctrl+D Ctrl+D - + &Recheck files + &Recheck files + + + Ctrl+R Ctrl+R - + &Stop &Stop - - + + Stop analysis Stop checking - + Esc Esc - + &Save results to file... &Save results to file... - + Ctrl+S Ctrl+S - + &Quit &Quit - + &Clear results &Clear results - + &Preferences &Preferences - - + + Show errors - - + + Show warnings - - + + Show performance warnings - + Show &hidden - - + + Information - + Show information messages - + Show portability warnings - + Show Cppcheck results - + Clang - + Show Clang results - + &Filter - + Filter results - + Windows 32-bit ANSI Windows 32-bit ANSI - + Windows 32-bit Unicode Windows 32-bit Unicode - + Unix 32-bit Unix 32-bit - + Unix 64-bit Unix 64-bit - + Windows 64-bit Windows 64-bit - + C++11 + C++11 + + + C99 + C99 + + + &Print... - + Print the Current Report - + Print Pre&view... - + Open a Print Preview Dialog for the Current Results - + Open library editor - + Gtk + Gtk + + + Posix + Posix + + + C11 + C11 + + + C89 + C89 + + + C++03 + C++03 + + + &Check all &Check all - + Filter - + &Reanalyze modified files &Recheck modified files - + Reanal&yze all files - + Ctrl+Q - + Style war&nings - + E&rrors - + &Uncheck all &Uncheck all - + Collapse &all Collapse &all - + &Expand all &Expand all - + &Standard - + Standard items - + Toolbar - + &Categories - + Error categories - + &Open XML... - + Open P&roject File... - + Ctrl+Shift+O - + Sh&ow Scratchpad... - + &New Project File... - + Ctrl+Shift+N - + &Log View - + Log View - + C&lose Project File - + &Edit Project File... - + &Statistics - + &Warnings - + Per&formance warnings - + &Information - + &Portability - + P&latforms - + C++&11 - + C&99 - + &Posix - + C&11 - + &C89 - + &C++03 - + &Library Editor... - + &Auto-detect language - + &Enforce C++ - + E&nforce C - + C++14 C++14 - + Reanalyze and check library - + Check configuration (defines, includes) - + C++17 C++17 - + C++20 C++20 - + &Contents - + Categories - - + + Show style warnings - + Open the help contents - + F1 F1 @@ -941,206 +984,226 @@ Parameters: -l(line) (file) &Help &Help + + Select directory to check + Select directory to check + + + No suitable files found to check! + No suitable files found to check! + - + Quick Filter: - + Select configuration - + Found project file: %1 Do you want to load this project file instead? - + File not found - + Bad XML - + Missing attribute - + Bad attribute value - + Failed to load the selected library '%1'. %2 - + License License - + Authors Authors - + XML files version 2 (*.xml);;XML files version 1 (*.xml);;Text files (*.txt);;CSV files (*.csv) + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) + + + Save the report file Save the report file - - + + XML files (*.xml) XML files (*.xml) - + There was a problem with loading the editor application settings. This is probably because the settings were changed between the Cppcheck versions. Please check (and fix) the editor application settings, otherwise the editor program might not start correctly. - + You must close the project file before selecting new files or directories! - + Select files to check + Select files to check + + + The library '%1' contains unknown elements: %2 - + Unsupported format - + Duplicate platform type - + Platform type redefined - + Unknown element - + Unknown issue - + Error - + Failed to load %1. Your Cppcheck installation is broken. You can use --data-dir=<directory> at the command line to specify where this file is located. Please note that --data-dir is supposed to be used by installation scripts and therefore the GUI does not start when it is used, all that happens is that the setting is configured. - + Open the report file - + Text files (*.txt) Text files (*.txt) - + CSV files (*.csv) - + Cppcheck - %1 + Cppcheck - %1 + + + Project files (*.cppcheck);;All files(*.*) - + Select Project File - - - + + + Project: - + No suitable files found to analyze! - + C/C++ Source - + Compile database - + Visual Studio - + Borland C++ Builder 6 - + Select files to analyze - + Select directory to analyze - + Select the configuration that will be analyzed - + Found project files from the directory. Do you want to proceed analysis without using any of these project files? - + Current results will be cleared. Opening a new XML file will clear current results. @@ -1148,54 +1211,54 @@ Do you want to proceed? - + Analyzer is running. Do you want to stop the analysis and exit Cppcheck? - + About - + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) - + Build dir '%1' does not exist, create it? - + To check the project using addons, you need a build directory. - + Failed to import '%1', analysis is stopped - + Project files (*.cppcheck) - + Select Project Filename - + No project file loaded - + The project file %1 @@ -1307,6 +1370,13 @@ Options: Windows 64-bit + + Project + + Cppcheck + Cppcheck + + ProjectFile @@ -1615,77 +1685,72 @@ Options: - + Select Cppcheck build dir - + Select include directory - + Select a directory to check - - (no rule texts file) - - - - + Clang-tidy (not found) - + Visual Studio - + Compile database - + Borland C++ Builder 6 - + Import Project - + Select directory to ignore - + Source files - + All files - + Exclude file - + Select MISRA rule texts file - + MISRA rule texts file (%1) @@ -1949,6 +2014,14 @@ Options: Recheck + + Copy filename + Copy filename + + + Copy full path + Copy full path + Hide @@ -2141,6 +2214,10 @@ To toggle what kind of errors are shown, open view menu. Copy complete Log + + No errors found, nothing to save. + No errors found, nothing to save. + diff --git a/gui/cppcheck_sv.ts b/gui/cppcheck_sv.ts index 9956ffbe7..6b3063c82 100644 --- a/gui/cppcheck_sv.ts +++ b/gui/cppcheck_sv.ts @@ -114,6 +114,10 @@ Parametrar: -l(line) (file) You must specify a name, a path and optionally parameters for the application! Du måste ange namn, sökväg samt eventuellt parametrar för applikationen! + + You must specify a name, a path and parameters for the application! + Du måste ange ett namn, en sökväg samt parametrar för programmet! + FileViewDialog @@ -391,6 +395,10 @@ Exempel: argvalue argvalue + + constant + constant + @@ -426,23 +434,58 @@ Exempel: Tillåtna värden + + LogView + + Checking Log + Analys logg + + + &Save + &Spara + + + Clear + Töm + + + Close + Stäng + + + Save Log + Spara logg + + + Text files (*.txt *.log);;All files (*.*) + Text filer (*.txt *.log);;Alla filer (*.*) + + + Cppcheck + Cppcheck + + + Could not open file for writing: "%1" + Kunde ej öppna fil för skrivning: "%1" + + MainWindow - - - - - - - - - - - - - + + + + + + + + + + + + + Cppcheck Cppcheck @@ -452,7 +495,7 @@ Exempel: Analysera - + Standard Standard @@ -471,487 +514,568 @@ Exempel: &Toolbars Verktygsfält + + &Check + &Check + C++ standard C++ standard - + &C standard C standard C standard - + &Edit &Redigera - + &License... &Licens... - + A&uthors... &Utvecklat av... - + &About... &Om... - + &Files... &Filer... - - + + Analyze files Check files Analysera filer - + Ctrl+F Ctrl+F - + &Directory... &Katalog... - - + + Analyze directory Check directory Analysera mapp - + Ctrl+D Ctrl+D - + &Recheck files + Starta &om check + + + Ctrl+R Ctrl+R - + &Reanalyze all files + &Recheck all files + Analysera om alla filer + + + &Stop &Stoppa - - + + Stop analysis Stop checking Stoppa analys - + Esc Esc - + &Save results to file... &Spara resultat till fil... - + Ctrl+S Ctrl+S - + &Quit &Avsluta - + &Clear results &Töm resultat - + &Preferences &Inställningar - - + Errors + Fel + + + + Show errors Visa fel - - + Show S&cratchpad... + Visa s&cratchpad... + + + Warnings + Varningar + + + + Show warnings Visa varningar - - + Performance warnings + Prestanda varningar + + + + Show performance warnings Visa prestanda varningar - + Show &hidden Visa dolda - - + + Information Information - + Show information messages Visa informations meddelanden - + Portability + Portabilitet + + + Show portability warnings Visa portabilitets varningar - + Show Cppcheck results Visa Cppcheck resultat - + Clang Clang - + Show Clang results Visa Clang resultat - + &Filter &Filter - + Filter results Filtrera resultat - + Windows 32-bit ANSI Windows 32-bit ANSI - + Windows 32-bit Unicode Windows 32-bit Unicode - + Unix 32-bit Unix 32-bit - + Unix 64-bit Unix 64-bit - + Windows 64-bit Windows 64-bit - + Platforms + Plattformar + + + C++11 + C++11 + + + C99 + C99 + + + Posix + Posix + + + C11 + C11 + + + C89 + C89 + + + C++03 + C++03 + + + &Print... Skriv ut... - + Print the Current Report Skriv ut aktuell rapport - + Print Pre&view... Förhandsgranska utskrift... - + Open a Print Preview Dialog for the Current Results Öppnar förhandsgranskning för nuvarande resultat - + Library Editor... + Library Editor... + + + Open library editor Öppna library editor - + Auto-detect language + Välj språk automatiskt + + + Enforce C++ + C++ + + + Enforce C + C + + + &Check all &Kryssa alla - + Filter Filter - + &Reanalyze modified files &Recheck modified files Analysera om ändrade filer - + Reanal&yze all files Analysera om alla filer - + Ctrl+Q - + Style war&nings Style varningar - + E&rrors Fel - + &Uncheck all Kryssa &ur alla - + Collapse &all Ingen bra översättning! &Fäll ihop alla - + &Expand all &Expandera alla - + &Standard &Standard - + Standard items Standard poster - + Toolbar Verktygsfält - + &Categories &Kategorier - + Error categories Fel kategorier - + &Open XML... &Öppna XML... - + Open P&roject File... Öppna Projektfil... - + Ctrl+Shift+O - + Sh&ow Scratchpad... Visa Scratchpad... - + &New Project File... Ny projektfil... - + Ctrl+Shift+N - + &Log View - + Log View Logg vy - + C&lose Project File Stäng projektfil - + &Edit Project File... Redigera projektfil... - + &Statistics Statistik - + &Warnings Varningar - + Per&formance warnings Optimerings varningar - + &Information Information - + &Portability Portabilitet - + P&latforms Plattformar - + C++&11 C++11 - + C&99 C99 - + &Posix Posix - + C&11 C11 - + &C89 C89 - + &C++03 C++03 - + &Library Editor... Library Editor... - + &Auto-detect language Detektera språk automatiskt - + &Enforce C++ Tvinga C++ - + E&nforce C Tvinga C - + C++14 C++14 - + Reanalyze and check library - + Check configuration (defines, includes) - + C++17 C++17 - + C++20 C++20 - + &Contents &Innehåll - + Categories Kategorier - - + Style warnings + Stil varningar + + + + Show style warnings Visa stil varningar - + Open the help contents Öppna hjälp - + F1 F1 @@ -960,19 +1084,35 @@ Exempel: &Help &Hjälp + + Select directory to check + Välj katalog som skall kontrolleras + + + No suitable files found to check! + Inga lämpliga filer hittades! + - + Quick Filter: Snabbfilter: - + C/C++ Source, Compile database, Visual Studio (%1 %2 *.sln *.vcxproj) + C/C++ källkod, Compile database, Visual Studio (%1 %2 *.sln *.vcxproj) + + + Select configuration Välj konfiguration - + Select the configuration that will be checked + Välj konfiguration som kommer analyseras + + + Found project file: %1 Do you want to load this project file instead? @@ -981,60 +1121,73 @@ Do you want to load this project file instead? Vill du ladda denna projektfil istället? - + Found project files from the directory. + +Do you want to proceed checking without using any of these project files? + Hittade projektfil(er) i mappen. + +Vill du fortsätta analysen utan att använda någon av dessa projektfiler? + + + File not found Filen hittades ej - + Bad XML Ogiltig XML - + Missing attribute Attribut finns ej - + Bad attribute value Ogiltigt attribut värde - + Unsupported format Format stöds ej - + Failed to load the selected library '%1'. %2 Misslyckades att ladda valda library '%1'. %2 - + License Licens - + Authors Utvecklare - + XML files version 2 (*.xml);;XML files version 1 (*.xml);;Text files (*.txt);;CSV files (*.csv) + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) + XML filer version 2 (*.xml);;XML filer version 1 (*.xml);;Text filer (*.txt);;CSV filer (*.csv) + + + Save the report file Spara rapport - - + + XML files (*.xml) XML filer (*.xml) - + There was a problem with loading the editor application settings. This is probably because the settings were changed between the Cppcheck versions. Please check (and fix) the editor application settings, otherwise the editor program might not start correctly. @@ -1043,122 +1196,174 @@ This is probably because the settings were changed between the Cppcheck versions En trolig orsak är att inställningarna ändrats för olika Cppcheck versioner. Kontrollera programinställningarna. - + You must close the project file before selecting new files or directories! Du måste stänga projektfilen innan nya filer eller sökvägar kan väljas! - + Select files to check + Välj filer att kontrollera + + + The library '%1' contains unknown elements: %2 Library filen '%1' har element som ej hanteras: %2 - + Duplicate platform type Dubbel plattformstyp - + Platform type redefined Plattformstyp definieras igen - + Unknown element Element hanteras ej - + Unknown issue Något problem - + Error Fel - + Failed to load %1. Your Cppcheck installation is broken. You can use --data-dir=<directory> at the command line to specify where this file is located. Please note that --data-dir is supposed to be used by installation scripts and therefore the GUI does not start when it is used, all that happens is that the setting is configured. Misslyckades att ladda %1. Din Cppcheck installation är ej komplett. Du kan använda --data-dir<directory> på kommandoraden för att specificera var denna fil finns. Det är meningen att --data-dir kommandot skall köras under installationen,så GUIt kommer ej visas när --data-dir används allt som händer är att en inställning görs. - + Current results will be cleared. + +Opening a new XML file will clear current results.Do you want to proceed? + Nuvarande resultat kommer rensas bort. + +När en ny XML fil öppnas så tas alla nuvarande resultat bort. Vill du fortsätta? + + + Open the report file Öppna rapportfilen - + Checking is running. + +Do you want to stop the checking and exit Cppcheck? + Cppcheck kör. + +Vill du stoppa analysen och avsluta Cppcheck? + + + XML files version 1 (*.xml) + XML filer version 1 (*.xml) + + + Deprecated XML format + Gammalt XML format + + + XML format 1 is deprecated and will be removed in cppcheck 1.81. + XML format 1 är gammalt och stödet kommer tas bort i Cppcheck 1.81 + + + XML files version 2 (*.xml) + XML filer version 2 (*.xml) + + + Text files (*.txt) Text filer (*.txt) - + CSV files (*.csv) CSV filer (*.csv) - + Cppcheck - %1 + Cppcheck - %1 + + + Failed to change the user interface language: + +%1 + +The user interface language has been reset to English. Open the Preferences-dialog to select any of the available languages. + Misslyckades att ändra språk: + +%1 + +Språket har nollställts till Engelska. Öppna Preferences och välj något av de tillgängliga språken. + + + Project files (*.cppcheck);;All files(*.*) Projektfiler (*.cppcheck);;Alla filer(*.*) - + Select Project File Välj projektfil - - - + + + Project: Projekt: - + No suitable files found to analyze! Inga filer hittades att analysera! - + C/C++ Source - + Compile database - + Visual Studio Visual Studio - + Borland C++ Builder 6 - + Select files to analyze Välj filer att analysera - + Select directory to analyze Välj mapp att analysera - + Select the configuration that will be analyzed Välj konfiguration som kommer analyseras - + Found project files from the directory. Do you want to proceed analysis without using any of these project files? @@ -1167,7 +1372,7 @@ Do you want to proceed analysis without using any of these project files? - + Current results will be cleared. Opening a new XML file will clear current results. @@ -1175,7 +1380,7 @@ Do you want to proceed? - + Analyzer is running. Do you want to stop the analysis and exit Cppcheck? @@ -1184,47 +1389,47 @@ Do you want to stop the analysis and exit Cppcheck? Vill du stoppa analysen och avsluta Cppcheck? - + About - + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) XML filer (*.xml);;Text filer (*.txt);;CSV filer (*.csv) - + Build dir '%1' does not exist, create it? Build dir '%1' existerar ej, skapa den? - + To check the project using addons, you need a build directory. - + Failed to import '%1', analysis is stopped Misslyckades att importera '%1', analysen stoppas - + Project files (*.cppcheck) Projekt filer (*.cppcheck) - + Select Project Filename Välj Projektfil - + No project file loaded Inget projekt laddat - + The project file %1 @@ -1239,6 +1444,30 @@ Do you want to remove the file from the recently used projects -list? kunde inte hittas! Vill du ta bort filen från 'senast använda projekt'-listan? + + + Cppcheck GUI. + +Syntax: + cppcheck-gui [OPTIONS] [files or paths] + +Options: + -h, --help Print this help + -p <file> Open given project file and start checking it + -l <file> Open given results xml file + -d <directory> Specify the directory that was checked to generate the results xml specified with -l + -v, --version Show program version + Cppcheck GUI. + +Syntax: + cppcheck-gui [OPTIONS] [files or paths] + +Options: + -h, --help Print this help + -p <file> Open given project file and start checking it + -l <file> Open given results xml file + -d <directory> Specify the directory that was checked to generate the results xml specified with -l + -v, --version Show program version @@ -1324,6 +1553,10 @@ Options: Platforms + + Built-in + Generell + Native @@ -1355,6 +1588,21 @@ Options: Windows 64-bit + + Project + + Cppcheck + Cppcheck + + + Could not read the project file. + Kunde ej läsa projektfilen. + + + Could not write the project file. + Kunde ej skriva projektfilen + + ProjectFile @@ -1362,11 +1610,30 @@ Options: Project File Projektfil + + Project + Projekt + + + <html><head/><body><p>In the build dir, cppcheck stores data about each translation unit.</p><p>With a build dir you get whole program analysis.</p><p>Unchanged files will be analyzed much faster; Cppcheck skip the analysis of these files and reuse their old data.</p></body></html> + I build dir sparar Cppcheck information för varje translation unit. +Med build dir får du whole program analys. +Omodifierade filer analyseras mycket fortare, Cppcheck hoppar över analysen och återanvänder den gamla informationen + + + Cppcheck build dir (whole program analysis, faster analysis for unchanged files) + Cppcheck build dir (whole program analys, snabbare analys för omodifierade filer) + Paths and Defines Sökvägar och defines + + <html><head/><body><p>Cppcheck can import Visual studio solutions (*.sln), Visual studio projects (*.vcxproj) or compile databases.</p><p>Files to check, defines, include paths are imported.</p></body></html> + Cppcheck kan importera Visual studio solutions (*.sln), Visual studio projekt (*.vcxproj) eller compile databases. +Sökvägar och defines importeras. + Import Project (Visual studio / compile database/ Borland C++ Builder 6) @@ -1379,11 +1646,24 @@ Options: Defines must be separated by a semicolon ';' Defines separeras med semicolon ';' + + &Root: + Root: + Rot: + + + Libraries: + Libraries: + Note: Put your own custom .cfg files in the same folder as the project file. You should see them above. Obs: Lägg dina egna .cfg filer i samma folder som projekt filen. De skall isåfall visas ovan. + + Visual Studio + Visual Studio + ... @@ -1521,6 +1801,14 @@ Options: External tools + + Includes + Include + + + Include directories: + Include sökvägar + Up @@ -1552,6 +1840,10 @@ Options: Cppcheck (built in) + + Clang + Clang + Check that each class has a safe public interface @@ -1603,11 +1895,19 @@ Options: Libraries Libraries + + Exclude + Exkludera + Suppressions Suppressions + + Suppression list: + Suppression-list: + Add @@ -1639,6 +1939,18 @@ Options: Coding standards Kodstandarder + + CERT + CERT + + + Extra Tools + Extra verktyg + + + It is common best practice to use several tools. + Best practice är att använda flera verktyg + Clang analyzer @@ -1663,80 +1975,110 @@ Options: Projektfil: %1 - - (no rule texts file) - - - - + Clang-tidy (not found) - + Select Cppcheck build dir Välj Cppcheck build dir - + Visual Studio (*.sln *.vcxproj);;Compile database (compile_commands.json) + Visual Studio (*.sln *.vcxproj);;Compile database (compile_commands.json) + + + Select include directory Välj include sökväg - + Source files - + All files - + Exclude file - + Select MISRA rule texts file - + MISRA rule texts file (%1) - + Select a directory to check Välj mapp att analysera - + Visual Studio Visual Studio - + Compile database - + Borland C++ Builder 6 - + Import Project Importera Projekt - + Visual Studio (*.sln *.vcxproj);;Compile database (compile_database.json) + Visual Studio (*.sln *.vcxproj);;Compile database (compile_database.json) + + + Select directory to ignore Välj sökväg att ignorera + + Add Suppression + Lägg till Suppression + + + Select error id suppress: + Välj error Id suppress: + + + + QDialogButtonBox + + OK + OK + + + Cancel + Avbryt + + + Close + Stäng + + + Save + Spara + QObject @@ -1984,6 +2326,10 @@ Options: Please select the directory where file is located. + + [Inconclusive] + [Inconclusive] + debug @@ -1999,6 +2345,22 @@ Options: Recheck Analysera om + + Copy filename + Kopiera filnamn + + + Copy full path + Kopiera full sökväg + + + Copy message + Kopiera meddelande + + + Copy message id + Kopiera meddelande id + Hide @@ -2068,6 +2430,14 @@ Please check the application path and parameters are correct. Kunde inte starta %1 Kontrollera att sökvägen och parametrarna är korrekta. + + + Could not find file: +%1 +Please select the directory where file is located. + Kunde inte hitta filen: +%1 +Välj mappen där filen finns. @@ -2166,6 +2536,14 @@ För att ställa in vilka fel som skall visas använd visa menyn. XML format version 1 is no longer supported. XML format version 1 stöds ej längre. + + Summary + Sammanfattning + + + Message + Meddelande + First included by @@ -2196,6 +2574,10 @@ För att ställa in vilka fel som skall visas använd visa menyn. Copy complete Log + + No errors found, nothing to save. + Inga fel hittades, ingenting att spara. + @@ -2217,6 +2599,10 @@ För att ställa in vilka fel som skall visas använd visa menyn. Warning Details Varningsdetaljer + + Functions + Funktioner + ScratchPad @@ -2258,6 +2644,10 @@ För att ställa in vilka fel som skall visas använd visa menyn. General Allmänt + + Include paths: + Include sökvägar: + Add... @@ -2396,6 +2786,14 @@ För att ställa in vilka fel som skall visas använd visa menyn. Custom + + Paths + Sökvägar + + + Edit + Redigera + Remove @@ -2437,6 +2835,18 @@ För att ställa in vilka fel som skall visas använd visa menyn. Language Språk + + Advanced + Avancerade + + + &Show inconclusive errors + Visa inconclusive meddelanden + + + S&how internal warnings in log + Visa interna fel i loggen + SettingsDialog @@ -2485,6 +2895,10 @@ För att ställa in vilka fel som skall visas använd visa menyn. Select clang path Välj Clang sökväg + + Select include directory + Välj include mapp + StatsDialog diff --git a/gui/cppcheck_zh_CN.ts b/gui/cppcheck_zh_CN.ts index 66105da0d..3f24d608b 100644 --- a/gui/cppcheck_zh_CN.ts +++ b/gui/cppcheck_zh_CN.ts @@ -40,6 +40,28 @@ of the GNU General Public License version 3 <html><head/><body><p>Many thanks to these libraries that we use:</p><ul style="margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; -qt-list-indent: 1;"><li style=" margin-top:12px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">pcre</li><li style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">picojson</li><li style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">qt</li><li style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">tinyxml2</li></ul></body></html> + + <html><head/><body> +<p>Many thanks to these libraries that we use:</p><ul> +<li>pcre</li> +<li>picojson</li> +<li>qt</li> +<li>tinyxml2</li> +<li>z3</li></ul></body></html> + <html><head/><body> +<p>Many thanks to these libraries that we use:</p><ul> +<li>tinyxml2</li> +<li>picojson</li> +<li>pcre</li> +<li>qt</li></ul></body></html> + <html><head/><body> +<p>非常感谢我们使用的这些库:</p><ul> +<li>pcre</li> +<li>picojson</li> +<li>qt</li> +<li>tinyxml2</li> +<li>z3</li></ul></body></html> + ApplicationDialog @@ -133,6 +155,21 @@ Parameters: -l(line) (file) 无法读取文件: %1 + + FunctionContractDialog + + Function contract + 函数约定 + + + Name + 名称 + + + Requirements for parameters + 必须的参数 + + HelpDialog @@ -427,23 +464,50 @@ Parameters: -l(line) (file) 有效值 + + LogView + + Checking Log + 正在检查记录 + + + Clear + 清空 + + + Save Log + 保存记录 + + + Text files (*.txt *.log);;All files (*.*) + 文本文件(*.txt *.log);;所有文件(*.*) + + + Cppcheck + Cppcheck + + + Could not open file for writing: "%1" + 无法打开并写入文件: “%1” + + MainWindow - - - - - - - - - - - - - + + + + + + + + + + + + + Cppcheck Cppcheck @@ -467,265 +531,325 @@ Parameters: -l(line) (file) &Help 帮助(&H) + + &Check + 检查(&C) + C++ standard C++ 标准 - + &C standard C standard &C 标准 - + &Edit 编辑(&E) - + Standard 标准 - + Categories 分类 - + &License... 许可证(&L)... - + A&uthors... 作者(&U)... - + &About... 关于(&A)... - + &Files... 文件(&F)... - - + + Analyze files Check files 分析文件 - + Ctrl+F Ctrl+F - + &Directory... 目录(&D)... - - + + Analyze directory Check directory 分析目录 - + Ctrl+D Ctrl+D - + &Recheck files + 重新检查文件(&R) + + + Ctrl+R Ctrl+R - + &Stop 停止(&S) - - + + Stop analysis Stop checking 停止分析 - + Esc Esc - + &Save results to file... 保存结果到文件(&S)... - + Ctrl+S Ctrl+S - + &Quit 退出(&Q) - + &Clear results 清空结果(&C) - + &Preferences 首选项(&P) - - + Style warnings + 风格警告 + + + + Show style warnings 显示风格警告 - - + Errors + 错误 + + + + Show errors 显示错误 - - + Show S&cratchpad... + 显示便条(&C)... + + + + Information 信息 - + Show information messages 显示信息消息 - + Portability + 移植可能性 + + + Show portability warnings 显示可移植性警告 - + Show Cppcheck results 显示 Cppcheck 结果 - + Clang Clang - + Show Clang results 显示 Clang 结果 - + &Filter 滤器(&F) - + Filter results 过滤结果 - + Windows 32-bit ANSI - + Windows 32-bit Unicode - + Unix 32-bit - + Unix 64-bit - + Windows 64-bit - + Platforms + 平台 + + + C++11 + C++11 + + + C99 + C99 + + + Posix + Posix + + + C11 + C11 + + + C89 + C89 + + + C++03 + C++03 + + + &Print... 打印(&P)... - + Print the Current Report 打印当前报告 - + Print Pre&view... 打印预览(&v)... - + Open a Print Preview Dialog for the Current Results 打开当前结果的打印预览窗口 - + Open library editor 打开库编辑器 - + C&lose Project File 关闭项目文件(&L) - + &Edit Project File... 编辑项目文件(&E)... - + &Statistics 统计(&S) - - + Warnings + 警告 + + + + Show warnings 显示警告 - - + Performance warnings + 性能警告 + + + + Show performance warnings 显示性能警告 - + Show &hidden 显示隐藏项(&H) - + &Check all 全部选中(&C) @@ -735,233 +859,233 @@ Parameters: -l(line) (file) 分析(&A) - + Filter 滤器 - + &Reanalyze modified files &Recheck modified files 重新分析已修改的文件(&R) - + Reanal&yze all files 重新分析全部文件(&y) - + Ctrl+Q Ctrl+Q - + Style war&nings 风格警告(&n) - + E&rrors 编辑(&r) - + &Uncheck all 全部取消选中(&U) - + Collapse &all 全部折叠(&A) - + &Expand all 全部展开(&E) - + &Standard 标准(&S) - + Standard items 标准项 - + &Contents 内容(&C) - + Open the help contents 打开帮助内容 - + F1 F1 - + Toolbar 工具栏 - + &Categories 分类(&C) - + Error categories 错误分类 - + &Open XML... 打开 XML (&O)... - + Open P&roject File... 打开项目文件(&R)... - + Ctrl+Shift+O Ctrl+Shift+O - + Sh&ow Scratchpad... 显示便条(&o)... - + &New Project File... 新建项目文件(&N)... - + Ctrl+Shift+N Ctrl+Shift+N - + &Log View 日志视图(&L) - + Log View 日志视图 - + &Warnings 警告(&W) - + Per&formance warnings 性能警告(&f) - + &Information 信息(&I) - + &Portability 可移植性(&P) - + P&latforms 平台(&l) - + C++&11 C++&11 - + C&99 C&99 - + &Posix &Posix - + C&11 C&11 - + &C89 &C89 - + &C++03 &C++03 - + &Library Editor... 库编辑器(&L)... - + &Auto-detect language 自动检测语言(&A) - + &Enforce C++ &Enforce C++ - + E&nforce C E&nforce C - + C++14 C++14 - + Reanalyze and check library 重新分析并检查库 - + Check configuration (defines, includes) 检查配置(defines, includes) - + C++17 C++17 - + C++20 C++20 - + There was a problem with loading the editor application settings. This is probably because the settings were changed between the Cppcheck versions. Please check (and fix) the editor application settings, otherwise the editor program might not start correctly. @@ -970,23 +1094,35 @@ This is probably because the settings were changed between the Cppcheck versions 这可能是因为 Cppcheck 不同版本间的设置有所不同。请检查(并修复)编辑器应用程序设置,否则编辑器程序可能不会正确启动。 - + No suitable files found to check! + 未发现适合检查的文件! + + + You must close the project file before selecting new files or directories! 在选择新的文件或目录之前,你必须先关闭此项目文件! + + Select directory to check + 选择目录来检查 + - + Quick Filter: 快速滤器: - + Select files to check + 选择要检查的文件 + + + Select configuration 选择配置 - + Found project file: %1 Do you want to load this project file instead? @@ -995,170 +1131,223 @@ Do you want to load this project file instead? 你是否想加载该项目文件? - + Found project files from the directory. + +Do you want to proceed checking without using any of these project files? + 在目录中找到项目文件。 + +你是否想在不使用这些项目文件的情况下,执行检查? + + + The library '%1' contains unknown elements: %2 库 '%1' 包含未知元素: %2 - + File not found 文件未找到 - + Bad XML 无效的 XML - + Missing attribute 缺失属性 - + Bad attribute value 无效的属性值 - + Unsupported format 不支持的格式 - + Duplicate platform type 重复的平台类型 - + Platform type redefined 平台类型重定义 - + Unknown element 位置元素 - + Unknown issue 未知问题 - + Failed to load the selected library '%1'. %2 选择的库 '%1' 加载失败。 %2 - + Error 错误 - + Failed to load %1. Your Cppcheck installation is broken. You can use --data-dir=<directory> at the command line to specify where this file is located. Please note that --data-dir is supposed to be used by installation scripts and therefore the GUI does not start when it is used, all that happens is that the setting is configured. 加载 %1 失败。您的 Cppcheck 安装已损坏。您可以在命令行添加 --data-dir=<目录> 参数来指定文件位置。请注意,'--data-dir' 参数应当由安装脚本使用,因此,当使用此参数时,GUI不会启动,所发生的一切只是配置了设置。 - - + Current results will be cleared. + +Opening a new XML file will clear current results.Do you want to proceed? + 当前结果将被清空。 + +打开一个新的 XML 文件将会清空当前结果。你要继续吗? + + + + XML files (*.xml) XML 文件(*.xml) - + Open the report file 打开报告文件 - + Checking is running. + +Do you want to stop the checking and exit Cppcheck? + 检查正在执行。 + +你是否需要停止检查并退出 Cppcheck? + + + License 许可证 - + Authors 作者 - + XML files version 2 (*.xml);;XML files version 1 (*.xml);;Text files (*.txt);;CSV files (*.csv) + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) + XML 文件版本 2 (*.xml);;XML 文件版本 1 (*.xml);; 文本文件(*.txt);; CSV 文件(*.csv) + + + Save the report file 保存报告文件 - + XML files version 1 (*.xml) + XML 文件版本 1 (*.xml) + + + XML files version 2 (*.xml) + XML 文件版本 2 (*.xml) + + + Text files (*.txt) 文本文件(*.txt) - + CSV files (*.csv) CSV 文件(*.csv) - + Cppcheck - %1 + Cppcheck - %1 + + + Failed to change the user interface language: + +%1 + +The user interface language has been reset to English. Open the Preferences-dialog to select any of the available languages. + 更改用户界面语言失败: + +%1 + +用户界面语言已被重置为英语。打开“首选项”对话框,选择任何可用的语言。 + + + Project files (*.cppcheck);;All files(*.*) 项目文件(*.cppcheck);;所有文件(*.*) - + Select Project File 选择项目文件 - - - + + + Project: 项目: - + No suitable files found to analyze! 没有找到合适的文件来分析! - + C/C++ Source C/C++ 源码 - + Compile database Compile database - + Visual Studio Visual Studio - + Borland C++ Builder 6 Borland C++ Builder 6 - + Select files to analyze 选择要分析的文件 - + Select directory to analyze 选择要分析的目录 - + Select the configuration that will be analyzed 选择要分析的配置 - + Found project files from the directory. Do you want to proceed analysis without using any of these project files? @@ -1167,7 +1356,7 @@ Do you want to proceed analysis without using any of these project files? - + Current results will be cleared. Opening a new XML file will clear current results. @@ -1178,7 +1367,7 @@ Do you want to proceed? 你想继续吗? - + Analyzer is running. Do you want to stop the analysis and exit Cppcheck? @@ -1187,47 +1376,47 @@ Do you want to stop the analysis and exit Cppcheck? 您想停止分析并退出 Cppcheck 吗? - + About - + XML files (*.xml);;Text files (*.txt);;CSV files (*.csv) XML 文件 (*.xml);;文本文件 (*.txt);;CSV 文件 (*.csv) - + Build dir '%1' does not exist, create it? 构建文件夹 '%1' 不能存在,创建它吗? - + To check the project using addons, you need a build directory. 要使用插件检查项目,您需要一个构建目录。 - + Failed to import '%1', analysis is stopped 导入 '%1' 失败,分析已停止 - + Project files (*.cppcheck) 项目文件 (*.cppcheck) - + Select Project Filename 选择项目文件名 - + No project file loaded 项目文件未加载 - + The project file %1 @@ -1326,6 +1515,10 @@ Options: Platforms + + Built-in + 内置 + Native @@ -1357,6 +1550,21 @@ Options: + + Project + + Cppcheck + Cppcheck + + + Could not read the project file. + 无法读取项目文件。 + + + Could not write the project file. + 无法写入项目文件。 + + ProjectFile @@ -1364,6 +1572,10 @@ Options: Project File 项目文件 + + Project + 项目 + Paths and Defines @@ -1381,6 +1593,11 @@ Options: Defines must be separated by a semicolon ';' 定义必须用分号分隔。例如:DEF1;DEF2=5;DEF3=int + + &Root: + Root: + 根目录: + Note: Put your own custom .cfg files in the same folder as the project file. You should see them above. @@ -1540,6 +1757,14 @@ Options: External tools 外部工具 + + Includes + 包含 + + + Include directories: + Include 目录: + Up @@ -1560,6 +1785,14 @@ Options: Clang (experimental) Clang (实验性的) + + Normal analysis -- Avoid false positives. + 常规分析 -- 避免误报。 + + + Bug hunting -- Generates mostly noise. The goal is to be "soundy" and detect most bugs. + 错误搜寻 -- 生成几乎所有提示。其目的是为了检测出大多数错误并使代码更加 "牢固"。 + If you want to design your classes to be as flexible and robust as possible then the public interface must be very robust. Cppcheck will asumme that arguments can take *any* value. @@ -1605,6 +1838,10 @@ Options: Libraries + + Exclude + 排除 + Suppressions @@ -1641,6 +1878,10 @@ Options: Coding standards 编码标准 + + CERT + CERT + Clang analyzer @@ -1665,81 +1906,87 @@ Options: 项目文件: %1 - + Select Cppcheck build dir 选择 Cppcheck 构建目录 - + Select include directory 选择 Include 目录 - + Select a directory to check 选择一个检查目录 - (no rule texts file) - (无规则文本文件) + (无规则文本文件) - + Clang-tidy (not found) Clang-tidy (未找到) - + Visual Studio Visual Studio - + Compile database Compile database - + Borland C++ Builder 6 Borland C++ Builder 6 - + Import Project 导入项目 - + Select directory to ignore 选择忽略的目录 - + Source files 源文件 - + All files 全部文件 - + Exclude file 排除文件 - + Select MISRA rule texts file 选择 MISRA 规则文本文件 - + MISRA rule texts file (%1) MISRA 规则文本文件 (%1) + + QDialogButtonBox + + Close + 关闭 + + QObject @@ -1984,6 +2231,10 @@ Options: Please select the directory where file is located. 请选择文件所在的目录。 + + [Inconclusive] + [不确定的] + debug @@ -1999,6 +2250,22 @@ Options: Recheck 重新检查 + + Copy filename + 复制文件名 + + + Copy full path + 复制完整路径 + + + Copy message + 复制消息 + + + Copy message id + 复制消息 ID + Hide @@ -2019,6 +2286,14 @@ Options: Open containing folder 打开包含的文件夹 + + Edit contract.. + 编辑约定.. + + + Suppress + 抑制 + @@ -2068,6 +2343,14 @@ Please check the application path and parameters are correct. 无法启动 %1 请检查此应用程序的路径与参数是否正确。 + + + Could not find file: +%1 +Please select the directory where file is located. + 无法找到文件: +%1 +请选择文件所在目录。 @@ -2137,6 +2420,30 @@ Please check the application path and parameters are correct. Warning Details 警告详情 + + Functions + 函数 + + + Variables + 变量 + + + Only show variable names that contain text: + 只显示包含文本的变量名: + + + Configured contracts: + 已配置的约定: + + + Missing contracts: + 缺失的约定: + + + No errors found, nothing to save. + 未发现错误,没有结果可保存。 + @@ -2187,6 +2494,14 @@ To toggle what kind of errors are shown, open view menu. XML format version 1 is no longer supported. 不再支持 XML 格式版本 1。 + + Summary + 概要 + + + Message + 消息 + First included by @@ -2258,6 +2573,10 @@ To toggle what kind of errors are shown, open view menu. General 常规 + + Include paths: + Include 路径: + Add... @@ -2396,6 +2715,14 @@ To toggle what kind of errors are shown, open view menu. Custom 自定义 + + Paths + 路径 + + + Edit + 编辑 + Remove @@ -2437,6 +2764,18 @@ To toggle what kind of errors are shown, open view menu. Language 语言 + + Advanced + 高级 + + + &Show inconclusive errors + 显示不确定的错误(&S) + + + S&how internal warnings in log + 在日记中显示内部警告(&H) + SettingsDialog @@ -2485,6 +2824,10 @@ To toggle what kind of errors are shown, open view menu. Select clang path 选择 clang 路径 + + Select include directory + 选择包含目录 + StatsDialog @@ -2777,6 +3120,25 @@ The user interface language has been reset to English. Open the Preferences-dial 不确定的 + + VariableContractsDialog + + Dialog + 对话框 + + + You can specify min and max value for the variable here + 你可以在这里指定变量的最小值和最大值 + + + Min + 最小 + + + Max + 最大 + + toFilterString diff --git a/gui/mainwindow.cpp b/gui/mainwindow.cpp index f54c1c309..ec52843ff 100644 --- a/gui/mainwindow.cpp +++ b/gui/mainwindow.cpp @@ -229,6 +229,7 @@ MainWindow::MainWindow(TranslationHandler* th, QSettings* settings) : mUI->mActionCpp14->setActionGroup(mCppStandardActions); mUI->mActionCpp17->setActionGroup(mCppStandardActions); mUI->mActionCpp20->setActionGroup(mCppStandardActions); + //mUI->mActionCpp23->setActionGroup(mCppStandardActions); mUI->mActionEnforceC->setActionGroup(mSelectLanguageActions); mUI->mActionEnforceCpp->setActionGroup(mSelectLanguageActions); @@ -315,6 +316,7 @@ void MainWindow::loadSettings() mUI->mActionCpp14->setChecked(standards.cpp == Standards::CPP14); mUI->mActionCpp17->setChecked(standards.cpp == Standards::CPP17); mUI->mActionCpp20->setChecked(standards.cpp == Standards::CPP20); + //mUI->mActionCpp23->setChecked(standards.cpp == Standards::CPP23); // Main window settings const bool showMainToolbar = mSettings->value(SETTINGS_TOOLBARS_MAIN_SHOW, true).toBool(); @@ -397,6 +399,8 @@ void MainWindow::saveSettings() const mSettings->setValue(SETTINGS_STD_CPP, "C++17"); if (mUI->mActionCpp20->isChecked()) mSettings->setValue(SETTINGS_STD_CPP, "C++20"); + //if (mUI.mActionCpp23->isChecked()) + // mSettings->setValue(SETTINGS_STD_CPP, "C++23"); // Main window settings mSettings->setValue(SETTINGS_TOOLBARS_MAIN_SHOW, mUI->mToolBarMain->isVisible()); diff --git a/gui/mainwindow.ui b/gui/mainwindow.ui index d4a0693d1..b2ccc3ad5 100644 --- a/gui/mainwindow.ui +++ b/gui/mainwindow.ui @@ -139,6 +139,7 @@ + @@ -840,6 +841,17 @@ C++20 + diff --git a/lib/checkother.cpp b/lib/checkother.cpp index 7e5f56136..2613a6576 100644 --- a/lib/checkother.cpp +++ b/lib/checkother.cpp @@ -3488,9 +3488,7 @@ void CheckOther::checkKnownArgument() continue; // ensure that function name does not contain "assert" std::string funcname = tok->astParent()->previous()->str(); - std::transform(funcname.begin(), funcname.end(), funcname.begin(), [](int c) { - return std::tolower(c); - }); + strTolower(funcname); if (funcname.find("assert") != std::string::npos) continue; knownArgumentError(tok, tok->astParent()->previous(), &tok->values().front(), varexpr, isVariableExprHidden); diff --git a/lib/importproject.cpp b/lib/importproject.cpp index 63317284b..4446f5ebd 100644 --- a/lib/importproject.cpp +++ b/lib/importproject.cpp @@ -37,6 +37,8 @@ #include +#include + #define PICOJSON_USE_INT64 #include @@ -314,18 +316,9 @@ void ImportProject::FileSettings::parseCommand(std::string command) ++pos; const std::string stdval = readUntil(command, &pos, " "); standard = stdval; + // TODO: use simplecpp::DUI::std instead of specifying it manually if (standard.compare(0, 3, "c++") || standard.compare(0, 5, "gnu++")) { - std::string stddef; - if (standard == "c++98" || standard == "gnu++98" || standard == "c++03" || standard == "gnu++03") { - stddef = "199711L"; - } else if (standard == "c++11" || standard == "gnu++11" || standard == "c++0x" || standard == "gnu++0x") { - stddef = "201103L"; - } else if (standard == "c++14" || standard == "gnu++14" || standard == "c++1y" || standard == "gnu++1y") { - stddef = "201402L"; - } else if (standard == "c++17" || standard == "gnu++17" || standard == "c++1z" || standard == "gnu++1z") { - stddef = "201703L"; - } - + const std::string stddef = simplecpp::getCppStdString(standard); if (stddef.empty()) { // TODO: log error continue; @@ -335,21 +328,7 @@ void ImportProject::FileSettings::parseCommand(std::string command) defs += stddef; defs += ";"; } else if (standard.compare(0, 1, "c") || standard.compare(0, 3, "gnu")) { - if (standard == "c90" || standard == "iso9899:1990" || standard == "gnu90" || standard == "iso9899:199409") { - // __STDC_VERSION__ is not set for C90 although the macro was added in the 1994 amendments - continue; - } - - std::string stddef; - - if (standard == "c99" || standard == "iso9899:1999" || standard == "gnu99") { - stddef = "199901L"; - } else if (standard == "c11" || standard == "iso9899:2011" || standard == "gnu11" || standard == "c1x" || standard == "gnu1x") { - stddef = "201112L"; - } else if (standard == "c17") { - stddef = "201710L"; - } - + const std::string stddef = simplecpp::getCStdString(standard); if (stddef.empty()) { // TODO: log error continue; @@ -808,14 +787,7 @@ bool ImportProject::importVcxproj(const std::string &filename, std::map &excludedPaths, bool caseSen { if (!mCaseSensitive) for (std::string& excludedPath : mExcludedPaths) - std::transform(excludedPath.begin(), excludedPath.end(), excludedPath.begin(), ::tolower); + strTolower(excludedPath); mWorkingDirectory.push_back(Path::getCurrentPath()); } @@ -44,7 +44,7 @@ bool PathMatch::match(const std::string &path) const std::string findpath = Path::fromNativeSeparators(path); if (!mCaseSensitive) - std::transform(findpath.begin(), findpath.end(), findpath.begin(), ::tolower); + strTolower(findpath); // Filtering directory name if (endsWith(excludedPath,'/')) { diff --git a/lib/preprocessor.cpp b/lib/preprocessor.cpp index 7b2067953..c029bc619 100644 --- a/lib/preprocessor.cpp +++ b/lib/preprocessor.cpp @@ -621,8 +621,11 @@ static simplecpp::DUI createDUI(const Settings &mSettings, const std::string &cf dui.undefined = mSettings.userUndefs; // -U dui.includePaths = mSettings.includePaths; // -I dui.includes = mSettings.userIncludes; // --include + // TODO: use mSettings.standards.stdValue instead if (Path::isCPP(filename)) dui.std = mSettings.standards.getCPP(); + else + dui.std = mSettings.standards.getC(); return dui; } diff --git a/lib/standards.h b/lib/standards.h index b667c0e35..e92656287 100644 --- a/lib/standards.h +++ b/lib/standards.h @@ -21,6 +21,8 @@ #define standardsH //--------------------------------------------------------------------------- +#include "utils.h" + #include /// @addtogroup Core @@ -32,17 +34,17 @@ * This struct contains all possible standards that cppcheck recognize. */ struct Standards { - /** C code C89/C99/C11 standard */ + /** C code standard */ enum cstd_t { C89, C99, C11, CLatest=C11 } c; /** C++ code standard */ - enum cppstd_t { CPP03, CPP11, CPP14, CPP17, CPP20, CPPLatest=CPP20 } cpp; + enum cppstd_t { CPP03, CPP11, CPP14, CPP17, CPP20, CPP23, CPPLatest=CPP23 } cpp; /** --std value given on command line */ std::string stdValue; /** This constructor clear all the variables **/ - Standards() : c(C11), cpp(CPPLatest) {} + Standards() : c(CLatest), cpp(CPPLatest) {} bool setC(const std::string& str) { stdValue = str; @@ -71,32 +73,29 @@ struct Standards { } return ""; } - bool setCPP(const std::string& str) { + static cstd_t getC(const std::string &std) { + if (std == "c89") { + return Standards::C89; + } + if (std == "c99") { + return Standards::C99; + } + if (std == "c11") { + return Standards::C11; + } + return Standards::CLatest; + } + bool setCPP(std::string str) { stdValue = str; - if (str == "c++03" || str == "C++03") { - cpp = CPP03; - return true; - } - if (str == "c++11" || str == "C++11") { - cpp = CPP11; - return true; - } - if (str == "c++14" || str == "C++14") { - cpp = CPP14; - return true; - } - if (str == "c++17" || str == "C++17") { - cpp = CPP17; - return true; - } - if (str == "c++20" || str == "C++20") { - cpp = CPP20; - return true; - } - return false; + strTolower(str); + cpp = getCPP(str); + return !stdValue.empty() && str == getCPP(); } std::string getCPP() const { - switch (cpp) { + return getCPP(cpp); + } + static std::string getCPP(cppstd_t std) { + switch (std) { case CPP03: return "c++03"; case CPP11: @@ -107,9 +106,32 @@ struct Standards { return "c++17"; case CPP20: return "c++20"; + case CPP23: + return "c++23"; } return ""; } + static cppstd_t getCPP(const std::string &std) { + if (std == "c++03") { + return Standards::CPP03; + } + if (std == "c++11") { + return Standards::CPP11; + } + if (std == "c++14") { + return Standards::CPP14; + } + if (std == "c++17") { + return Standards::CPP17; + } + if (std == "c++20") { + return Standards::CPP20; + } + if (std == "c++23") { + return Standards::CPP23; + } + return Standards::CPPLatest; + } }; /// @} diff --git a/lib/utils.cpp b/lib/utils.cpp index 413404dbc..e5b31d98b 100644 --- a/lib/utils.cpp +++ b/lib/utils.cpp @@ -18,6 +18,7 @@ #include "utils.h" +#include #include #include #include @@ -120,3 +121,13 @@ bool matchglobs(const std::vector &patterns, const std::string &nam return matchglob(pattern, name); }); } + +void strTolower(std::string& str) +{ + // This wrapper exists because Sun's CC does not allow a static_cast + // from extern "C" int(*)(int) to int(*)(int). + static auto tolowerWrapper = [](int c) { + return std::tolower(c); + }; + std::transform(str.begin(), str.end(), str.begin(), tolowerWrapper); +} diff --git a/lib/utils.h b/lib/utils.h index 75cbe8245..21993d637 100644 --- a/lib/utils.h +++ b/lib/utils.h @@ -154,4 +154,6 @@ CPPCHECKLIB bool matchglob(const std::string& pattern, const std::string& name); CPPCHECKLIB bool matchglobs(const std::vector &patterns, const std::string &name); +CPPCHECKLIB void strTolower(std::string& str); + #endif diff --git a/test/testcmdlineparser.cpp b/test/testcmdlineparser.cpp index 870875095..12229f59a 100644 --- a/test/testcmdlineparser.cpp +++ b/test/testcmdlineparser.cpp @@ -104,6 +104,7 @@ private: TEST_CASE(reportProgressTest); // "Test" suffix to avoid hiding the parent's reportProgress TEST_CASE(stdc99); TEST_CASE(stdcpp11); + TEST_CASE(stdunknown); TEST_CASE(platform); TEST_CASE(plistEmpty); TEST_CASE(plistDoesNotExist); @@ -711,6 +712,22 @@ private: ASSERT(settings.standards.cpp == Standards::CPP11); } + void stdunknown() { + REDIRECT; + { + CLEAR_REDIRECT_OUTPUT; + const char *const argv[] = {"cppcheck", "--std=d++11", "file.cpp"}; + ASSERT(!defParser.parseFromArgs(3, argv)); + ASSERT_EQUALS("cppcheck: error: unknown --std value 'd++11'\n", GET_REDIRECT_OUTPUT); + } + { + CLEAR_REDIRECT_OUTPUT; + const char *const argv[] = {"cppcheck", "--std=cplusplus11", "file.cpp"}; + TODO_ASSERT(!defParser.parseFromArgs(3, argv)); + TODO_ASSERT_EQUALS("cppcheck: error: unknown --std value 'cplusplus11'\n", "", GET_REDIRECT_OUTPUT); + } + } + void platform() { REDIRECT; const char * const argv[] = {"cppcheck", "--platform=win64", "file.cpp"}; diff --git a/test/testpreprocessor.cpp b/test/testpreprocessor.cpp index 776de5f06..a24530426 100644 --- a/test/testpreprocessor.cpp +++ b/test/testpreprocessor.cpp @@ -209,6 +209,7 @@ private: TEST_CASE(predefine3); TEST_CASE(predefine4); TEST_CASE(predefine5); // automatically define __cplusplus + TEST_CASE(predefine6); // automatically define __STDC_VERSION__ TEST_CASE(invalidElIf); // #2942 segfault @@ -1996,8 +1997,14 @@ private: void predefine5() { // #3737, #5119 - automatically define __cplusplus // #3737... const char code[] = "#ifdef __cplusplus\n123\n#endif"; - ASSERT_EQUALS("", preprocessor0.getcode(code, "X=123", "test.c")); - ASSERT_EQUALS("\n123", preprocessor0.getcode(code, "X=123", "test.cpp")); + ASSERT_EQUALS("", preprocessor0.getcode(code, "", "test.c")); + ASSERT_EQUALS("\n123", preprocessor0.getcode(code, "", "test.cpp")); + } + + void predefine6() { // automatically define __STDC_VERSION__ + const char code[] = "#ifdef __STDC_VERSION__\n123\n#endif"; + ASSERT_EQUALS("\n123", preprocessor0.getcode(code, "", "test.c")); + ASSERT_EQUALS("", preprocessor0.getcode(code, "", "test.cpp")); } void invalidElIf() {