Text_surface.cpp の動作サンプル
#include <iostream>
#include <SDL.h>
using namespace hrk;
using namespace std;
int main(int argc, char *argv[])
{
const char* font_file = (argc >= 2) ? argv[1] : "";
main_window.
show(
SizeF(640, 480));
Scene* scene = view.
front();
Layer* layer = scene->
front();
cout <<
"Font::open(): " << font.
what() << endl;
return 1;
}
Label hello_label(&hello_text);
Label jp_label(&jp_text);
layer->
push_front(&hello_label);
layer->push_front(&jp_label);
jp_label.
set_position(
PointF(0, hello_label.
size().
height()));
view.redraw();
delay_sec(1.5);
return 0;
}