KiCad PCB EDA Suite
pgm_base.cpp File Reference

For the main application: init functions, and language selection (locale handling) More...

#include <fctsys.h>
#include <wx/html/htmlwin.h>
#include <wx/fs_zip.h>
#include <wx/dir.h>
#include <wx/filename.h>
#include <wx/snglinst.h>
#include <wx/stdpaths.h>
#include <wx/sysopt.h>
#include <wx/richmsgdlg.h>
#include <pgm_base.h>
#include <eda_draw_frame.h>
#include <eda_base_frame.h>
#include <macros.h>
#include <config_params.h>
#include <id.h>
#include <build_version.h>
#include <hotkeys_basic.h>
#include <gestfich.h>
#include <menus_helpers.h>
#include <confirm.h>
#include <dialog_configure_paths.h>
#include <lockfile.h>
#include <systemdirsappend.h>
#include <trace_helpers.h>
#include <gal/gal_display_options.h>

Go to the source code of this file.

Macros

#define KICAD_COMMON   wxT( "kicad_common" )
 
#define _(s)   s
 LanguagesList Note: because this list is not created on the fly, wxTranslation must be called when a language name must be displayed after translation. More...
 
#define _(s)   wxGetTranslation((s))
 LanguagesList Note: because this list is not created on the fly, wxTranslation must be called when a language name must be displayed after translation. More...
 

Variables

static const wxChar languageCfgKey [] = wxT( "LanguageID" )
 
static const wxChar pathEnvVariables [] = wxT( "EnvironmentVariables" )
 
static const wxChar showEnvVarWarningDialog [] = wxT( "ShowEnvVarWarningDialog" )
 
static const wxChar traceEnvVars [] = wxT( "KIENVVARS" )
 
LANGUAGE_DESCR LanguagesList []
 

Detailed Description

For the main application: init functions, and language selection (locale handling)

Definition in file pgm_base.cpp.

Macro Definition Documentation

◆ _ [1/2]

#define _ (   s)    s

LanguagesList Note: because this list is not created on the fly, wxTranslation must be called when a language name must be displayed after translation.

Do not change this behavior, because m_Lang_Label is also used as key in config

Definition at line 110 of file pgm_base.cpp.

◆ _ [2/2]

#define _ (   s)    wxGetTranslation((s))

LanguagesList Note: because this list is not created on the fly, wxTranslation must be called when a language name must be displayed after translation.

Do not change this behavior, because m_Lang_Label is also used as key in config

Definition at line 110 of file pgm_base.cpp.

◆ KICAD_COMMON

#define KICAD_COMMON   wxT( "kicad_common" )

Definition at line 60 of file pgm_base.cpp.

Variable Documentation

◆ languageCfgKey

const wxChar languageCfgKey[] = wxT( "LanguageID" )
static

Definition at line 66 of file pgm_base.cpp.

Referenced by PGM_BASE::SetLanguage().

◆ LanguagesList

LANGUAGE_DESCR LanguagesList[]
Initial value:
=
{
{ wxLANGUAGE_DEFAULT, ID_LANGUAGE_DEFAULT, lang_def_xpm, _( "Default" ), false },
{ wxLANGUAGE_ENGLISH, ID_LANGUAGE_ENGLISH, lang_en_xpm, wxT( "English" ), true },
{ wxLANGUAGE_FRENCH, ID_LANGUAGE_FRENCH, lang_fr_xpm, _( "French" ), false },
{ wxLANGUAGE_FINNISH, ID_LANGUAGE_FINNISH, lang_fi_xpm, _( "Finnish" ), false },
{ wxLANGUAGE_SPANISH, ID_LANGUAGE_SPANISH, lang_es_xpm, _( "Spanish" ), false },
{ wxLANGUAGE_PORTUGUESE, ID_LANGUAGE_PORTUGUESE, lang_pt_xpm, _( "Portuguese" ), false },
{ wxLANGUAGE_ITALIAN, ID_LANGUAGE_ITALIAN, lang_it_xpm, _( "Italian" ), false },
{ wxLANGUAGE_GERMAN, ID_LANGUAGE_GERMAN, lang_de_xpm, _( "German" ), false },
{ wxLANGUAGE_GREEK, ID_LANGUAGE_GREEK, lang_gr_xpm, _( "Greek" ), false },
{ wxLANGUAGE_SLOVENIAN, ID_LANGUAGE_SLOVENIAN, lang_sl_xpm, _( "Slovenian" ), false },
{ wxLANGUAGE_SLOVAK, ID_LANGUAGE_SLOVAK, lang_sk_xpm, _( "Slovak" ), false },
{ wxLANGUAGE_HUNGARIAN, ID_LANGUAGE_HUNGARIAN, lang_hu_xpm, _( "Hungarian" ), false },
{ wxLANGUAGE_POLISH, ID_LANGUAGE_POLISH, lang_pl_xpm, _( "Polish" ), false },
{ wxLANGUAGE_CZECH, ID_LANGUAGE_CZECH, lang_cs_xpm, _( "Czech" ), false },
{ wxLANGUAGE_RUSSIAN, ID_LANGUAGE_RUSSIAN, lang_ru_xpm, _( "Russian" ), false },
{ wxLANGUAGE_KOREAN, ID_LANGUAGE_KOREAN, lang_ko_xpm, _( "Korean" ), false },
{ wxLANGUAGE_CHINESE_SIMPLIFIED, ID_LANGUAGE_CHINESE_SIMPLIFIED, lang_zh_xpm,
_( "Chinese simplified" ), false },
{ wxLANGUAGE_CHINESE_TRADITIONAL, ID_LANGUAGE_CHINESE_TRADITIONAL, lang_zh_xpm,
_( "Chinese traditional" ), false },
{ wxLANGUAGE_CATALAN, ID_LANGUAGE_CATALAN, lang_ca_xpm, _( "Catalan" ), false },
{ wxLANGUAGE_DUTCH, ID_LANGUAGE_DUTCH, lang_nl_xpm, _( "Dutch" ), false },
{ wxLANGUAGE_JAPANESE, ID_LANGUAGE_JAPANESE, lang_jp_xpm, _( "Japanese" ), false },
{ wxLANGUAGE_BULGARIAN, ID_LANGUAGE_BULGARIAN, lang_bg_xpm, _( "Bulgarian" ), false },
{ wxLANGUAGE_LITHUANIAN, ID_LANGUAGE_LITHUANIAN, lang_lt_xpm, _( "Lithuanian" ), false },
{ 0, 0, lang_def_xpm, "", false }
}
const BITMAP_OPAQUE lang_hu_xpm[1]
Definition: lang_hu.cpp:24
const BITMAP_OPAQUE lang_def_xpm[1]
Definition: lang_def.cpp:115
const BITMAP_OPAQUE lang_ca_xpm[1]
Definition: lang_ca.cpp:27
const BITMAP_OPAQUE lang_nl_xpm[1]
Definition: lang_nl.cpp:23
const BITMAP_OPAQUE lang_sl_xpm[1]
Definition: lang_sl.cpp:29
const BITMAP_OPAQUE lang_bg_xpm[1]
Definition: lang_bg.cpp:19
const BITMAP_OPAQUE lang_cs_xpm[1]
Definition: lang_cs.cpp:33
const BITMAP_OPAQUE lang_fr_xpm[1]
Definition: lang_fr.cpp:24
const BITMAP_OPAQUE lang_sk_xpm[1]
Definition: lang_sk.cpp:38
const BITMAP_OPAQUE lang_es_xpm[1]
Definition: lang_es.cpp:30
const BITMAP_OPAQUE lang_zh_xpm[1]
Definition: lang_zh.cpp:28
const BITMAP_OPAQUE lang_jp_xpm[1]
Definition: lang_jp.cpp:31
const BITMAP_OPAQUE lang_ru_xpm[1]
Definition: lang_ru.cpp:23
const BITMAP_OPAQUE lang_fi_xpm[1]
Definition: lang_fi.cpp:27
const BITMAP_OPAQUE lang_lt_xpm[1]
Definition: lang_lt.cpp:23
const BITMAP_OPAQUE lang_gr_xpm[1]
Definition: lang_gr.cpp:32
const BITMAP_OPAQUE lang_en_xpm[1]
Definition: lang_en.cpp:53
const BITMAP_OPAQUE lang_de_xpm[1]
Definition: lang_de.cpp:24
const BITMAP_OPAQUE lang_ko_xpm[1]
Definition: lang_ko.cpp:53
#define _(s)
LanguagesList Note: because this list is not created on the fly, wxTranslation must be called when a ...
Definition: pgm_base.cpp:110
const BITMAP_OPAQUE lang_pl_xpm[1]
Definition: lang_pl.cpp:22
const BITMAP_OPAQUE lang_pt_xpm[1]
Definition: lang_pt.cpp:35
const BITMAP_OPAQUE lang_it_xpm[1]
Definition: lang_it.cpp:24

Definition at line 80 of file pgm_base.cpp.

Referenced by AddMenuLanguageList(), PGM_BASE::SetLanguage(), and PGM_BASE::SetLanguageIdentifier().

◆ pathEnvVariables

const wxChar pathEnvVariables[] = wxT( "EnvironmentVariables" )
static

◆ showEnvVarWarningDialog

const wxChar showEnvVarWarningDialog[] = wxT( "ShowEnvVarWarningDialog" )
static

Definition at line 68 of file pgm_base.cpp.

Referenced by PGM_BASE::loadCommonSettings(), and PGM_BASE::SaveCommonSettings().

◆ traceEnvVars

const wxChar traceEnvVars[] = wxT( "KIENVVARS" )
static