1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36
| #include <gtkmm/main.h>
#include <gtkmm/window.h>
#include <gtkmm/box.h>
#include <gtkmm/label.h>
#include <iostream>
#include <windows.h>
#include <locale.h>
using namespace std;
string toAscii(char tab[]) {
char buffer[256];
CharToOemA(tab, buffer);
string str(buffer);
return str;
}
int main(int argc, char* argv[]) {
setlocale(LC_ALL, "");
Gtk::Main app(argc, argv);
Gtk::Window fenetre;
fenetre.set_title("Starlox");
Gtk::VBox boiteV(true, 10);
Gtk::Label etiquette1(toAscii("Bonne année mon frère de François"));
Gtk::Label etiquette2("Etiquette 2");
boiteV.pack_start(etiquette1);
boiteV.pack_start(etiquette2);
fenetre.add(boiteV);
fenetre.show_all();
Gtk::Main::run(fenetre);
return 0;
} |
Partager