diff options
author | Tim Angus <tim@ngus.net> | 2007-10-30 18:18:47 +0000 |
---|---|---|
committer | Tim Angus <tim@ngus.net> | 2007-10-30 18:18:47 +0000 |
commit | 1e0b515a6031a2cd2a77e9c34f2e4292fc9f9750 (patch) | |
tree | 51193c4f5cac62d5c5626c360c80218bc7fab71c /src/cgame/cg_local.h | |
parent | e552cbda632662d32ffccc662c6d12ec1cc54719 (diff) |
* (bug 3384) Remove server side armoury refresh and replace with UI side
refresh
* Add trap_Key_SetOverstrikeMode and trap_Key_GetOverstrikeMode to cgame
* Change Text_[Width|Height] to return floats
* Add Text_Em[Width|Height]
* Add CG_AlignText to cut down on code duplication
* Add itemDef_t::textvalignment for vertical text alignment
* Add UI_DrawTextBlock to replace a lot of duplicate code
* Rewrite text wrapping code from scratch so that it actually works
* Add UI_OwnerDrawText
* Add expression evaluator to .menu parser
* Split off Border_Paint from Window_Paint
* Scale slider items to fit their rect
* Rework edit field widgets to behave somewhat more correctly
* Fix a few listbox widget layout issues
* Don't display scrollbars in "notselectable" listbox widgets
* Make scoreboard team labels ownerdrawn
* Menu script rework
+ Use the expression evaluator to replace lots and lots of absolute
coords with relative ones, hopefully easing future maintenance
+ Remove lots and lots of textalign[xy] that were present to work
around broken text alignment routines
+ Replace a bunch of numeric constants with ones from menudef.h
+ Compose the huds from tremulous_common_hud.h
+ Generally neaten things up
+ Lots of whitespace fixes
Diffstat (limited to 'src/cgame/cg_local.h')
-rw-r--r-- | src/cgame/cg_local.h | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/src/cgame/cg_local.h b/src/cgame/cg_local.h index 2ed268e7..3816218b 100644 --- a/src/cgame/cg_local.h +++ b/src/cgame/cg_local.h @@ -1585,12 +1585,16 @@ void CG_AddLagometerFrameInfo( void ); void CG_AddLagometerSnapshotInfo( snapshot_t *snap ); void CG_CenterPrint( const char *str, int y, int charWidth ); void CG_DrawActive( stereoFrame_t stereoView ); -void CG_OwnerDraw( float x, float y, float w, float h, float text_x, float text_y, - int ownerDraw, int ownerDrawFlags, int align, float special, - float scale, vec4_t color, qhandle_t shader, int textStyle); +void CG_OwnerDraw( float x, float y, float w, float h, float text_x, + float text_y, int ownerDraw, int ownerDrawFlags, + int align, int textalign, int textvalign, float special, + float scale, vec4_t color, + qhandle_t shader, int textStyle ); void CG_Text_Paint( float x, float y, float scale, vec4_t color, const char *text, float adjust, int limit, int style ); -int CG_Text_Width( const char *text, float scale, int limit ); -int CG_Text_Height( const char *text, float scale, int limit ); +float CG_Text_Width( const char *text, float scale, int limit ); +float CG_Text_Height( const char *text, float scale, int limit ); +float CG_Text_EmWidth( float scale ); +float CG_Text_EmHeight( float scale ); float CG_GetValue(int ownerDraw); void CG_RunMenuScript(char **args); void CG_SetPrintString( int type, const char *p ); @@ -2020,6 +2024,8 @@ int trap_Key_GetKey( const char *binding ); void trap_Key_KeynumToStringBuf( int keynum, char *buf, int buflen ); void trap_Key_GetBindingBuf( int keynum, char *buf, int buflen ); void trap_Key_SetBinding( int keynum, const char *binding ); +void trap_Key_SetOverstrikeMode( qboolean state ); +qboolean trap_Key_GetOverstrikeMode( void ); int trap_CIN_PlayCinematic( const char *arg0, int xpos, int ypos, int width, int height, int bits ); e_status trap_CIN_StopCinematic( int handle ); |