Add links to list of library contributors on GitHub

- Apologies to "leet hackers"
- Add URL option to contributor entity
This commit is contained in:
Oliver 2017-12-12 00:56:32 +11:00 committed by Wayne Stambaugh
parent 5f6f03b16c
commit 0871719cc9
3 changed files with 68 additions and 8 deletions

View File

@ -253,94 +253,117 @@ static void buildKicadAboutBanner( EDA_BASE_FRAME* aParent, ABOUT_APP_INFO& aInf
* and as icon the national flag of the corresponding country.
*/
aInfo.AddTranslator( new CONTRIBUTOR( "Robert Buj",
wxEmptyString,
wxEmptyString,
"Catalan (CA)",
KiBitmapNew( lang_catalan_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( wxT( "Martin Kratoška" ),
wxEmptyString,
wxEmptyString,
"Czech (CZ)",
KiBitmapNew( lang_cs_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Jerry Jacobs",
wxEmptyString,
wxEmptyString,
"Dutch (NL)",
KiBitmapNew( lang_nl_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Vesa Solonen",
wxEmptyString,
wxEmptyString,
"Finnish (FI)",
KiBitmapNew( lang_fi_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Jean-Pierre Charras",
wxEmptyString,
wxEmptyString,
"French (FR)",
KiBitmapNew( lang_fr_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( wxT( "Mateusz Skowroński" ),
wxEmptyString,
wxEmptyString,
"Polish (PL)",
KiBitmapNew( lang_pl_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Kerusey Karyu",
wxEmptyString,
wxEmptyString,
"Polish (PL)",
KiBitmapNew( lang_pl_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Renie Marquet",
wxEmptyString,
wxEmptyString,
"Portuguese (PT)",
KiBitmapNew( lang_pt_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Igor Plyatov",
wxEmptyString,
wxEmptyString,
"Russian (RU)",
KiBitmapNew( lang_ru_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Andrey Fedorushkov",
wxEmptyString,
wxEmptyString,
"Russian (RU)",
KiBitmapNew( lang_ru_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Eldar Khayrullin",
wxEmptyString,
wxEmptyString,
"Russian (RU)",
KiBitmapNew( lang_ru_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Pedro Martin del Valle",
wxEmptyString,
wxEmptyString,
"Spanish (ES)",
KiBitmapNew( lang_es_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( wxT( "Iñigo Zuluaga" ),
wxEmptyString,
wxEmptyString,
"Spanish (ES)",
KiBitmapNew( lang_es_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( wxT( "Iñigo Figuero" ),
wxEmptyString,
wxEmptyString,
"Spanish (ES)",
KiBitmapNew( lang_es_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Rafael Sokolowski",
wxEmptyString,
wxEmptyString,
"German (DE)",
KiBitmapNew( lang_de_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Kenta Yonekura",
wxEmptyString,
wxEmptyString,
"Japanese (JA)",
KiBitmapNew( lang_jp_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Manolis Stefanis",
wxEmptyString,
wxEmptyString,
"Greek (el_GR)",
KiBitmapNew( lang_gr_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Athanasios Vlastos",
wxEmptyString,
wxEmptyString,
"Greek (el_GR)",
KiBitmapNew( lang_gr_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Milonas Kostas",
wxEmptyString,
wxEmptyString,
"Greek (el_GR)",
KiBitmapNew( lang_gr_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Michail Misirlis",
wxEmptyString,
wxEmptyString,
"Greek (el_GR)",
KiBitmapNew( lang_gr_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Massimo Cioce",
wxEmptyString,
wxEmptyString,
"Italian (IT)",
KiBitmapNew( lang_it_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Marco Ciampa",
wxEmptyString,
wxEmptyString,
"Italian (IT)",
KiBitmapNew( lang_it_xpm ) ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Evgeniy Ivanov",
wxEmptyString,
wxEmptyString,
"Bulgarian (BG)",
KiBitmapNew( lang_bg_xpm ) ) );
@ -348,53 +371,69 @@ static void buildKicadAboutBanner( EDA_BASE_FRAME* aParent, ABOUT_APP_INFO& aInf
// Maintainer who helper in translations, but not in a specific translation
#define OTHERS_IN_TRANSLATION _( "Others" )
aInfo.AddTranslator( new CONTRIBUTOR( "Remy Halvick",
wxEmptyString,
wxEmptyString,
OTHERS_IN_TRANSLATION ) );
aInfo.AddTranslator( new CONTRIBUTOR( "David Briscoe",
wxEmptyString,
wxEmptyString,
OTHERS_IN_TRANSLATION ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Dominique Laigle",
wxEmptyString,
wxEmptyString,
OTHERS_IN_TRANSLATION ) );
aInfo.AddTranslator( new CONTRIBUTOR( "Paul Burke",
wxEmptyString,
wxEmptyString,
OTHERS_IN_TRANSLATION ) );
// Programm credits for icons
#define ICON_CONTRIBUTION _( "Icons by" )
aInfo.AddArtist( new CONTRIBUTOR( wxT( "Iñigo Zuluaga" ),
wxEmptyString,
wxEmptyString,
ICON_CONTRIBUTION,
KiBitmapNew( svg_file_xpm ) ) );
aInfo.AddArtist( new CONTRIBUTOR( "Konstantin Baranovskiy",
wxEmptyString,
wxEmptyString,
ICON_CONTRIBUTION,
KiBitmapNew( svg_file_xpm ) ) );
aInfo.AddArtist( new CONTRIBUTOR( "Fabrizio Tappero",
wxEmptyString,
wxEmptyString,
ICON_CONTRIBUTION,
KiBitmapNew( svg_file_xpm ) ) );
// Program credits for 3d models
#define MODELS_3D_CONTRIBUTION _( "3D models by" )
aInfo.AddArtist( new CONTRIBUTOR( "GitHub contributors",
wxEmptyString,
"https://github.com/KiCad/kicad-packages3D/graphs/contributors",
MODELS_3D_CONTRIBUTION,
KiBitmapNew( three_d_xpm ) ) );
aInfo.AddArtist( new CONTRIBUTOR( "Christophe Boschat",
wxEmptyString,
wxEmptyString,
MODELS_3D_CONTRIBUTION,
KiBitmapNew( three_d_xpm ) ) );
aInfo.AddArtist( new CONTRIBUTOR( "Renie Marquet",
wxEmptyString,
wxEmptyString,
MODELS_3D_CONTRIBUTION,
KiBitmapNew( three_d_xpm ) ) );
#define SYMBOL_LIB_CONTRIBUTION _( "Symbols by" )
aInfo.AddArtist( new CONTRIBUTOR( "Leet Hacker1",
aInfo.AddArtist( new CONTRIBUTOR( "GitHub contributors",
wxEmptyString,
"https://github.com/KiCad/kicad-symbols/graphs/contributors",
SYMBOL_LIB_CONTRIBUTION,
KiBitmapNew( edit_component_xpm ) ) );
#define FOOTPRINT_LIB_CONTRIBUTION _( "Footprints by" )
aInfo.AddArtist( new CONTRIBUTOR( "Leet Hacker2",
aInfo.AddArtist( new CONTRIBUTOR( "GitHub contributors",
wxEmptyString,
"https://github.com/KiCad/kicad-footprints/graphs/contributors",
FOOTPRINT_LIB_CONTRIBUTION,
KiBitmapNew( edit_module_xpm ) ) );

View File

@ -138,11 +138,13 @@ class CONTRIBUTOR
public:
CONTRIBUTOR( const wxString& aName,
const wxString& aEmail = wxEmptyString,
const wxString& aUrl = wxEmptyString,
const wxString& aCategory = wxEmptyString,
wxBitmap* aIcon = NULL )
{
m_checked = false;
m_name = aName;
m_url = aUrl,
m_email = aEmail;
m_category = aCategory;
m_icon = aIcon;
@ -152,6 +154,7 @@ public:
wxString& GetName() { return m_name; }
wxString& GetEMail() { return m_email; }
wxString& GetUrl() { return m_url; }
wxString& GetCategory() { return m_category; }
wxBitmap* GetIcon() { return m_icon; }
void SetChecked( bool status ) { m_checked = status; }
@ -160,6 +163,7 @@ public:
private:
wxString m_name;
wxString m_email;
wxString m_url;
wxString m_category;
wxBitmap* m_icon;
bool m_checked;

View File

@ -39,6 +39,7 @@ extern std::string GetCurlLibVersion();
#include <boost/version.hpp>
#include <wx/clipbrd.h>
#include <wx/msgdlg.h>
#include <wx/hyperlink.h>
/* All KiCad icons are linked into shared library 'libbitmaps.a'.
* Icons:
@ -251,13 +252,29 @@ void DIALOG_ABOUT::createNotebookPageByCategory(wxAuiNotebook* aParent, const wx
// First column is empty
fgSizer1->AddSpacer(5);
// Name of contributor at second column
wxStaticText* m_staticText2 = new wxStaticText( m_scrolledWindow1, wxID_ANY,
wxT("") + sub_contributor->GetName(),
wxDefaultPosition,
wxDefaultSize, 0 );
wxControl* ctrl;
// No URL supplied, display normal text control
if( sub_contributor->GetUrl().IsEmpty() )
{
ctrl = new wxStaticText( m_scrolledWindow1, wxID_ANY,
wxT( "" ) + sub_contributor->GetName(),
wxDefaultPosition,
wxDefaultSize, 0 );
}
else
{
// Display a hyperlink control instead
ctrl = new wxHyperlinkCtrl( m_scrolledWindow1, wxID_ANY,
wxT( "" ) + sub_contributor->GetName(),
sub_contributor->GetUrl(),
wxDefaultPosition,
wxDefaultSize, wxHL_ALIGN_LEFT );
}
m_staticText1->Wrap( -1 );
fgSizer1->Add( m_staticText2, 0, wxALIGN_LEFT|wxBOTTOM, 2 );
fgSizer1->Add( ctrl, 0, wxALIGN_LEFT|wxBOTTOM, 2 );
// Email address of contributor at third column
if( sub_contributor->GetEMail() != wxEmptyString )