Thanks for all the answers, I was already kinda giving up on this
IzNoGods fullscreen align thought and the search through ui/menudefinition.h got me the answer, now it's nice and clean
PHP Code:
#define RECT4(_rect_) \
rect _rect_ HORIZONTAL_ALIGN_DEFAULT VERTICAL_ALIGN_DEFAULT
#define ITEM(_rect, _dvar) \
itemDef \
{ \
name "window" \
group ingamebox \
visible 1 \
RECT4(_rect) \
origin ORIGIN_QUICKMESSAGEWINDOW \
forecolor 1 1 1 1 \
textfont UI_FONT_NORMAL \
textscale .24 \
textaligny 8 \
dvar _dvar \
decoration \
}
ITEM(16 20 0 0, "menu_1")
ITEM(16 36 0 0, "menu_2")
ITEM(16 52 0 0, "menu_3")
ITEM(16 68 0 0, "menu_4")
ITEM(16 84 0 0, "menu_5")
ITEM(16 100 0 0, "menu_6")
ITEM(16 116 0 0, "menu_7")
ITEM(16 132 0 0, "menu_8")
ITEM(16 148 0 0, "menu_9")
ITEM(16 164 0 0, "menu_0")
So basically just replaced:
HORIZONTAL_ALIGN_FULLSCREEN VERTICAL_ALIGN_FULLSCREEN
with:
HORIZONTAL_ALIGN_DEFAULT VERTICAL_ALIGN_DEFAULT
Here are the other definitions, they may help somebody out later:
PHP Code:
// Edge relative placement values for rect->h_align and rect->v_align
#define HORIZONTAL_ALIGN_SUBLEFT 0 // left edge of a 4:3 screen (safe area not included)
#define HORIZONTAL_ALIGN_LEFT 1 // left viewable (safe area) edge
#define HORIZONTAL_ALIGN_CENTER 2 // center of the screen (reticle)
#define HORIZONTAL_ALIGN_RIGHT 3 // right viewable (safe area) edge
#define HORIZONTAL_ALIGN_FULLSCREEN 4 // disregards safe area
#define HORIZONTAL_ALIGN_NOSCALE 5 // uses exact parameters - neither adjusts for safe area nor scales for screen size
#define HORIZONTAL_ALIGN_TO640 6 // scales a real-screen resolution x down into the 0 - 640 range
#define HORIZONTAL_ALIGN_CENTER_SAFEAREA 7 // center of the safearea
#define HORIZONTAL_ALIGN_MAX HORIZONTAL_ALIGN_CENTER_SAFEAREA
#define HORIZONTAL_ALIGN_DEFAULT HORIZONTAL_ALIGN_SUBLEFT
#define VERTICAL_ALIGN_SUBTOP 0 // top edge of the 4:3 screen (safe area not included)
#define VERTICAL_ALIGN_TOP 1 // top viewable (safe area) edge
#define VERTICAL_ALIGN_CENTER 2 // center of the screen (reticle)
#define VERTICAL_ALIGN_BOTTOM 3 // bottom viewable (safe area) edge
#define VERTICAL_ALIGN_FULLSCREEN 4 // disregards safe area
#define VERTICAL_ALIGN_NOSCALE 5 // uses exact parameters - neither adjusts for safe area nor scales for screen size
#define VERTICAL_ALIGN_TO480 6 // scales a real-screen resolution y down into the 0 - 480 range
#define VERTICAL_ALIGN_CENTER_SAFEAREA 7 // center of the save area
#define VERTICAL_ALIGN_MAX VERTICAL_ALIGN_CENTER_SAFEAREA
#define VERTICAL_ALIGN_DEFAULT VERTICAL_ALIGN_SUBTOP