SOURCE V19 BUTTONS

12/02/2012 19:18 adeilson123#1

========================================
ITheme.cpp:
========================================

search:

Code:
#ifdef __LANG_1013
	PLANG_DATA pLangData	= CLangMan::GetInstance()->GetLangData( ::GetLanguage() );
	CD3DFont* pFont;
put down:
Code:
#ifdef __v19BUTTONS

        pFont = new CD3DFont( _T("Verdana"), 9, D3DFONT_BOLD );
	m_mapFont.SetAt( _T( "ButtonV19"), pFont );

#endif// __v19BUTTONS
search:
Code:
	m_mapFont.Lookup( _T("Arial Black9"), (void*&)m_pFontWndTitle );
put down:
Code:
#ifdef __v19BUTTONS
	m_mapFont.Lookup( _T("ButtonV19"), (void*&)m_pFontButton );
#endif//__v19BUTTONS
to make writing appear on the buttons need only that, the rest is the source,
position etc.
-----------------------------------------------------------------------------
search:
Code:
		RenderWndButton_4Texture( p2DRender, pWndButton );
put down:
Code:
#ifdef __v19BUTTONS
	    RenderWndButtonText(p2DRender,pWndButton);
#endif// __v19BUTTONS

-----------------------------------------------------------------------------
search :
Code:
void CTheme::RenderWndButtonText( C2DRender* p2DRender, CWndButton* pWndButton  )
replace all:
Code:
#ifdef __v19BUTTONS
void CTheme::RenderWndButtonText( C2DRender* p2DRender, CWndButton* pWndButton  )
{
	BOOL  bHighLight  = pWndButton->IsHighLight();
	BOOL  bEnable     = pWndButton->IsWindowEnabled();
	BOOL  bPush       = pWndButton->IsPush();
	DWORD dwColor     = GetButtonFontColor( pWndButton );
	POINT pt          = GetButtonTextPos( p2DRender, pWndButton );

	CD3DFont* pFont = p2DRender->GetFont();
	p2DRender->SetFont( CWndBase::m_Theme.m_pFontButton ); 

	if ( pWndButton->IsPush() )
	{    
		p2DRender->TextOut( pt.x, pt.y + 2, pWndButton->GetTitle(), dwColor );
	}
	else
	{
		p2DRender->TextOut( pt.x, pt.y + 1, pWndButton->GetTitle(), dwColor );
	}

	p2DRender->SetFont( pFont );
}
#endif//__v19BUTTONS
========================================
ITheme.h
========================================
search:
Code:
	CD3DFont* m_pFontWndTitle;
put down:

Code:
#ifdef __v19BUTTONS
	CD3DFont* m_pFontButton
#endif//__v19BUTTONS
========================================
WndControl.cpp
========================================
search:
Code:
CWndButton::CWndButton()
{
replace them by those:

Code:
#ifdef __v19BUTTONS
	m_nFontColor      = D3DCOLOR_ARGB( 255, 10, 10, 10 );
	m_nPushColor      = D3DCOLOR_ARGB( 255, 64, 64, 64 );
	m_nDisableColor   = D3DCOLOR_ARGB( 255, 15, 15, 15 );
	m_nHighlightColor = D3DCOLOR_ARGB( 255, 80, 80, 80 );

#endif//__v19BUTTONS
========================================
Neuz VersionCommon.h
========================================
Code:
#define __v19BUTTONS
this is just to bring up the writings of the buttons to change the design of the buttons you guys should change the theme for v19

Code 100% created by me

picuture
[Only registered and activated users can see links. Click Here To Register...]
[Only registered and activated users can see links. Click Here To Register...]
[Only registered and activated users can see links. Click Here To Register...]
[Only registered and activated users can see links. Click Here To Register...]

12/02/2012 20:03 BattleTale#2
ist zwar schon in fast jeder Source drin, vondaher kann man es sich leicht raussuchen.

Aber danke für deine mühe.
12/02/2012 20:39 Jopsi332#3
Die version ist scheiße weil man auf wirklcih alle Buttons den Text schreibt und nicht nur auf die, auf denen es sein muss. Also HF beim resdata.txt.txt ändern, hast ja dann nen haufen an mehr arbeit als nötig.
12/02/2012 20:45 sbobetcom#4
Thank so much
12/02/2012 20:45 adeilson123#5
Quote:
Originally Posted by Jopsi332 View Post
Die version ist scheiße weil man auf wirklcih alle Buttons den Text schreibt und nicht nur auf die, auf denen es sein muss. Also HF beim resdata.txt.txt ändern, hast ja dann nen haufen an mehr arbeit als nötig.

have you ever looked at the official v19?
I think not because he had looked he would see
that within the official resdata.txt.txt
are written the names of all buttons
12/02/2012 20:52 Jopsi332#6
Quote:
Originally Posted by adeilson123 View Post
have you ever looked at the official v19?
I think not because he had looked he would see
that within the official resdata.txt.txt
are written the names of all buttons
start 1time daisy and save and all other buttons will have textes you dont need on the buttons.

And i saw some things on resdata.txt.txt like placeholderxx
12/02/2012 21:03 adeilson123#7
Quote:
Originally Posted by Jopsi332 View Post
start 1time daisy and save and all other buttons will have textes you dont need on the buttons.

And i saw some things on resdata.txt.txt like placeholderxx
for you use this system buttons
you are required to change the resdata.h, resdata.inc and resdata.txt.txt
for official v19 ....

I did it tested, works perfectly without bugs
12/02/2012 21:06 Jopsi332#8
Quote:
Originally Posted by adeilson123 View Post
for you use this system buttons
you are required to change the resdata.h, resdata.inc and resdata.txt.txt
for official v19 ....

I did it tested, works perfectly without bugs
if you save the path of buttons and make an if if it is the right button(buttnormalxx.tga) he only make it with the one who needed and not for all. a bit more ram needed but i think perfomce is better cause he make on a window not 10 renderbuttontext maybe only 2 then.
12/02/2012 21:08 ademir321#9
Thank so much
12/02/2012 21:18 adeilson123#10
Quote:
Originally Posted by Jopsi332 View Post
if you save the path of buttons and make an if if it is the right button(buttnormalxx.tga) he only make it with the one who needed and not for all. a bit more ram needed but i think perfomce is better cause he make on a window not 10 renderbuttontext maybe only 2 then.
jopsi put your system
for us to see
12/02/2012 21:26 sbobetcom#11
[Only registered and activated users can see links. Click Here To Register...]

i try to do but still no text in botton How can i edit more?

Thank you
12/03/2012 03:02 Jarryve Dayllon#12
*cough*
12/03/2012 05:46 Rhyder`#13
no text on button fail giving source :3
12/03/2012 15:05 Pixelfehler#14
WndControl.cpp
m_pTheme->RenderWndButtonText( p2DRender, this );
Finished.
12/05/2012 13:01 guiieduardo#15
if I put it in my v18 will work?