Created
August 4, 2022 14:19
-
-
Save sp00ck/4a48e30426720de4cfc29bc50e3c35fc to your computer and use it in GitHub Desktop.
g++ -Wall -pedantic -pedantic-errors -g -L~/wx/lib `~/wx/wx-config --cxxflags --unicode` -DwxUSE_GUI=0 -L~/wx/lib `~/wx/wx-config --libs --unicode` bl.cpp -o bl
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <wx/wx.h> | |
#include <wx/app.h> | |
#include <wx/cmdline.h> | |
#include <wx/intl.h> | |
wxLocale* locale; | |
int main(void) | |
{ | |
wxString a,b; | |
wxInitializer initializer; | |
locale = new wxLocale( wxLANGUAGE_POLISH ); | |
if ( !initializer.IsOk() ) | |
{ fprintf(stderr, "Nie udało się znaleźć bibliotek programu"); return -1; } | |
a = wxT("bardzo|dziwny|tekst|itd|"); | |
b = a.BeforeFirst(wxT("|")); | |
wxPrintf("pierwszy [%ls]\n", b ); | |
// wxPrintf("przedostatni [%s]\n", a.BeforeLast(wxT("|")) ); | |
delete(locale); | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
not working BeforeLast