GameApi 28
Library used by GameApi Builder tool
Loading...
Searching...
No Matches
ui.cc File Reference
#include "ui.hh"
#include <sstream>
#include <iostream>
#include <fstream>
#include <map>
#include <functional>
Include dependency graph for ui.cc:

Classes

class  FromStreamClass2< T >
class  FromStreamClass2< std::string >
class  FromStreamClass2< unsigned int >
class  FromStreamClass2< std::vector< T > >
class  ApiItem< RT, P >
class  EmptyWidget
class  LabelWidget
class  LinkWidget
class  GameApiAnimation
class  ImageWidget
class  ScriptButton
class  ChildSizeWidget
class  FormWidget
class  SubmitWidget
class  EditorWidget
class  PasswordEditorWidget

Macros

#define MACRO(lab)

Functions

std::string hexify (std::string s)
std::string unhexify (std::string s)
std::string Pixels (int val)
std::string Colour (unsigned int colour)
std::string unique_id_apiitem ()
W add_w (Widget *w)
Widget * find_w (W w)
 MACRO (W)
template<typename T>
T from_stream22 (std::stringstream &is)
template<class RT, class... P>
int funccall (RT(fptr)(P...), std::vector< std::string > s, std::vector< std::string > param_name)
template<class RT, class... P>
Item * ApiItemF (RT(*fptr)(P...), std::string name, std::vector< std::string > param_name, std::vector< std::string > param_type, std::vector< std::string > param_default, std::string return_type, std::string func_name)
std::string api_name ()
int num_displays ()
std::string type_symbol ()
void display (int i, int disp)
int add (void *w)
void * find (int i)
std::vector< Item * > functions ()
W empty ()
W gameapi_animation (std::string num, int sx, int sy)
W list_y (std::vector< W > v, int gap_y)
W list_x (std::vector< W > v, int gap_x)
W label (std::string str, int size_x, int size_y, int font_size, unsigned int font_colour, int align)
W link (std::string url, std::string str, int size_x, int size_y, int font_size, unsigned int font_colour, int align)
W layer (std::vector< W > v)
std::string gen_html_page (W w)
W image (std::string url, int size_x, int size_y)
W gradient (int i, int size_x, int size_y)
int grid_x_pos (int val, int sx)
int grid_y_pos (int val, int sx)
W grid_y (std::vector< W > v, int sx, int gap_x, int gap_y)
W margin (W widget, int left, int top, int right, int bottom)
W right_align (W item, int sx)
W center_align (W item, int sx)
W center_y (W item, int sy)
W hide (W widget)
W image_placeholder (int size_x, int size_y)
W child_size (W w)
W form (W vec, bool is_get, std::string script_url)
W submit_button (std::string label, int size_x, int size_y)
W editor (std::string name, std::string value, std::string placeholder, int size_x, int size_y, int font_size, unsigned int font_colour, int align)
W password_editor (std::string name, std::string value, std::string placeholder, int size_x, int size_y, int font_size, unsigned int font_colour, int align)

Variables

std::vector< Widget * > envimpl

Macro Definition Documentation

◆ MACRO

#define MACRO ( lab)
Value:
template<> \
class FromStreamClass2<lab> \
{ \
public:\
lab from_stream(std::string s)\
{\
lab bm;\
std::stringstream is(unhexify(s)); \
is >> bm.id;\
return bm;\
}\
};
std::string unhexify(std::string s)
Definition accel.cc:21
Definition accel.cc:84

Function Documentation

◆ add()

int add ( void * w)
Here is the caller graph for this function:

◆ add_w()

W add_w ( Widget * w)
Here is the caller graph for this function:

◆ api_name()

std::string api_name ( )

◆ ApiItemF()

template<class RT, class... P>
Item * ApiItemF ( RT(* fptr )(P...),
std::string name,
std::vector< std::string > param_name,
std::vector< std::string > param_type,
std::vector< std::string > param_default,
std::string return_type,
std::string func_name )
Here is the caller graph for this function:

◆ center_align()

W center_align ( W item,
int sx )
Here is the caller graph for this function:

◆ center_y()

W center_y ( W item,
int sy )
Here is the caller graph for this function:

◆ child_size()

W child_size ( W w)
Here is the caller graph for this function:

◆ Colour()

std::string Colour ( unsigned int colour)
Here is the caller graph for this function:

◆ display()

void display ( int i,
int disp )

◆ editor()

W editor ( std::string name,
std::string value,
std::string placeholder,
int size_x,
int size_y,
int font_size,
unsigned int font_colour,
int align )
Here is the caller graph for this function:

◆ empty()

W empty ( )
Here is the caller graph for this function:

◆ find()

void * find ( int i)
Here is the caller graph for this function:

◆ find_w()

Widget * find_w ( W w)
Here is the caller graph for this function:

◆ form()

W form ( W vec,
bool is_get,
std::string script_url )
Here is the caller graph for this function:

◆ from_stream22()

template<typename T>
T from_stream22 ( std::stringstream & is)
Here is the caller graph for this function:

◆ funccall()

template<class RT, class... P>
int funccall ( RT(fptr)(P...) ,
std::vector< std::string > s,
std::vector< std::string > param_name )
Here is the caller graph for this function:

◆ functions()

std::vector< Item * > functions ( )

◆ gameapi_animation()

W gameapi_animation ( std::string num,
int sx,
int sy )
Here is the caller graph for this function:

◆ gen_html_page()

std::string gen_html_page ( W w)
Here is the caller graph for this function:

◆ gradient()

W gradient ( int i,
int size_x,
int size_y )
Here is the caller graph for this function:

◆ grid_x_pos()

int grid_x_pos ( int val,
int sx )
Here is the caller graph for this function:

◆ grid_y()

W grid_y ( std::vector< W > v,
int sx,
int gap_x,
int gap_y )
Here is the caller graph for this function:

◆ grid_y_pos()

int grid_y_pos ( int val,
int sx )
Here is the caller graph for this function:

◆ hexify()

std::string hexify ( std::string s)
Here is the caller graph for this function:

◆ hide()

W hide ( W widget)
Here is the caller graph for this function:

◆ image()

W image ( std::string url,
int size_x,
int size_y )

◆ image_placeholder()

W image_placeholder ( int size_x,
int size_y )
Here is the caller graph for this function:

◆ label()

W label ( std::string str,
int size_x,
int size_y,
int font_size,
unsigned int font_colour,
int align )
Here is the caller graph for this function:

◆ layer()

W layer ( std::vector< W > v)
Here is the caller graph for this function:

◆ link()

W link ( std::string url,
std::string str,
int size_x,
int size_y,
int font_size,
unsigned int font_colour,
int align )
Here is the caller graph for this function:

◆ list_x()

W list_x ( std::vector< W > v,
int gap_x )
Here is the caller graph for this function:

◆ list_y()

W list_y ( std::vector< W > v,
int gap_y )
Here is the caller graph for this function:

◆ MACRO()

MACRO ( W )

◆ margin()

W margin ( W widget,
int left,
int top,
int right,
int bottom )

◆ num_displays()

int num_displays ( )

◆ password_editor()

W password_editor ( std::string name,
std::string value,
std::string placeholder,
int size_x,
int size_y,
int font_size,
unsigned int font_colour,
int align )
Here is the caller graph for this function:

◆ Pixels()

std::string Pixels ( int val)
Here is the caller graph for this function:

◆ right_align()

W right_align ( W item,
int sx )
Here is the caller graph for this function:

◆ submit_button()

W submit_button ( std::string label,
int size_x,
int size_y )
Here is the caller graph for this function:

◆ type_symbol()

std::string type_symbol ( )

◆ unhexify()

std::string unhexify ( std::string s)
Here is the caller graph for this function:

◆ unique_id_apiitem()

std::string unique_id_apiitem ( )
Here is the caller graph for this function:

Variable Documentation

◆ envimpl

std::vector<Widget*> envimpl