mirror of
https://gitea.wildfiregames.com/0ad/0ad.git
synced 2026-07-26 00:15:04 +00:00
Attempted Linuxness
This was SVN commit r543.
This commit is contained in:
@@ -192,9 +192,33 @@
|
||||
<Filter
|
||||
Name="platform"
|
||||
Filter="">
|
||||
<File
|
||||
RelativePath=".\platform\msw\fontselect.cpp">
|
||||
</File>
|
||||
<Filter
|
||||
Name="msw"
|
||||
Filter="">
|
||||
<File
|
||||
RelativePath=".\platform\msw\fontselect.cpp">
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="linux"
|
||||
Filter="">
|
||||
<File
|
||||
RelativePath=".\platform\linux\fontselect.cpp">
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"
|
||||
ExcludedFromBuild="TRUE">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ObjectFile="$(IntDir)/$(InputName)1.obj"/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Release|Win32">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ObjectFile="$(IntDir)/$(InputName)1.obj"/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
</Filter>
|
||||
</Filter>
|
||||
</Filter>
|
||||
<Filter
|
||||
|
||||
@@ -114,6 +114,13 @@
|
||||
<FileConfiguration
|
||||
Name="Release|Win32"/>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\platform\linux\fontselect.cpp">
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"/>
|
||||
<FileConfiguration
|
||||
Name="Release|Win32"/>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\filemanip.h">
|
||||
<FileConfiguration
|
||||
|
||||
@@ -1,23 +1,29 @@
|
||||
// $Id: fontselect.h,v 1.1 2004/06/17 19:32:04 philip Exp $
|
||||
// $Id: fontselect.h,v 1.2 2004/06/18 22:05:58 philip Exp $
|
||||
|
||||
class FontSelectorDialog : public wxDialog
|
||||
{
|
||||
public:
|
||||
FontSelectorDialog(wxWindow* parent);
|
||||
#ifdef _WIN32
|
||||
~FontSelectorDialog();
|
||||
#endif
|
||||
|
||||
wxString FontName;
|
||||
wxString FontFilename;
|
||||
|
||||
#ifdef _WIN32
|
||||
void OnFontSelect(wxCommandEvent& event);
|
||||
void OnOK(wxCommandEvent& event);
|
||||
#endif
|
||||
|
||||
static void DefaultFonts(wxString& Name0, wxString& Filename0, wxString& Name1, wxString& Filename1);
|
||||
|
||||
private:
|
||||
|
||||
#ifdef _WIN32
|
||||
wxArrayString FontNames;
|
||||
wxCharBuffer** FontFilenames;
|
||||
#endif
|
||||
|
||||
DECLARE_EVENT_TABLE()
|
||||
};
|
||||
|
||||
+29
@@ -0,0 +1,29 @@
|
||||
// $Id: fontselect.cpp,v 1.1 2004/06/18 22:05:58 philip Exp $
|
||||
|
||||
#include "stdafx.h"
|
||||
|
||||
#include "../fontselect.h"
|
||||
|
||||
FontSelectorDialog::FontSelectorDialog(wxWindow* parent)
|
||||
: wxDialog(parent, -1, wxString(wxT("Font selector")), wxDefaultPosition, wxSize(400, 200), wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER)
|
||||
{
|
||||
wxFileDialog Dlg (this, wxT("Select a font file"), wxEmptyString, wxEmptyString, wxT("TTF files (*.ttf)|*.ttf|All files (*.*)|*.*"), wxOPEN | wxHIDE_READONLY)
|
||||
if (Dlg.ShowModal() == wxID_OK)
|
||||
{
|
||||
FontName = Dlg.GetFilename();
|
||||
FontFilename = Dlg.GetPath();
|
||||
EndModal(wxID_OK);
|
||||
}
|
||||
else
|
||||
{
|
||||
EndModal(wxID_CANCEL);
|
||||
}
|
||||
}
|
||||
|
||||
void FontSelectorDialog::DefaultFonts(wxString& Name0, wxString& Filename0, wxString& Name1, wxString& Filename1)
|
||||
{
|
||||
Name0 = wxT("Please select");
|
||||
Filename0 = wxT("");
|
||||
Name1 = wxT("Please select");
|
||||
Filename1 = wxT("");
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
// $Id: stdafx.h,v 1.1 2004/06/17 19:32:04 philip Exp $
|
||||
// $Id: stdafx.h,v 1.2 2004/06/18 22:05:58 philip Exp $
|
||||
|
||||
// Precompiled headers
|
||||
|
||||
@@ -7,11 +7,11 @@
|
||||
|
||||
// Disable some complaints in wx headers
|
||||
#pragma warning (push)
|
||||
#pragma warning (disable: 4267 4311 1125)
|
||||
#pragma warning (disable: 4267 4311)
|
||||
|
||||
#ifdef __INTEL_COMPILER
|
||||
// Disable some of the excessively pedantic icl /W4 warnings (remarks)
|
||||
#pragma warning (disable: 193 373 444 981 383 1418)
|
||||
#pragma warning (disable: 193 373 444 981 383 1125 1418)
|
||||
#endif
|
||||
|
||||
// Include relevant wx headers
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// $Id: wxapp.cpp,v 1.1 2004/06/17 19:32:04 philip Exp $
|
||||
// $Id: wxapp.cpp,v 1.2 2004/06/18 22:05:58 philip Exp $
|
||||
|
||||
#include "stdafx.h"
|
||||
|
||||
@@ -19,7 +19,7 @@ bool FontBuilderApp::OnInit()
|
||||
{
|
||||
ConfigInit();
|
||||
|
||||
MainFrame *frame = new MainFrame(wxString::Format(wxT("Font Builder %s"), version), wxDefaultPosition, wxSize(640,480));
|
||||
MainFrame *frame = new MainFrame(wxString::Format(wxT("Font Builder %s"), (const wchar_t*)version), wxDefaultPosition, wxSize(640,480));
|
||||
frame->SetIcon(wxIcon(wxT("IDI_ICON1")));
|
||||
frame->Show(true);
|
||||
SetTopWindow(frame);
|
||||
|
||||
Reference in New Issue
Block a user