示例#1
0
	//------------------------------------------------------------------------------
	void			CGUIWgtScrollPanel::ProcessProperty( const CGUIProperty* pProperty)
	{
		CGUIWidget::ProcessProperty(pProperty);
		
		////////////////////////////////////////////////////////////////////////////////////////////////////
		//property for parent
		/*
		*<property name="SHOW_VERT_SCROLLBAR" type="BOOL" value="true" />
		*/
		if( pProperty->GetName() == "SHOW_VERT_SCROLLBAR" && pProperty->GetType()=="BOOL")
		{
			ForceVertScrollbarShow(StringToValue(pProperty->GetValue()));
		}
		else if( pProperty->GetName() == "SHOW_HORZ_SCROLLBAR" && pProperty->GetType()=="BOOL")
		{
			ForceHorzScrollbarShow(StringToValue(pProperty->GetValue()));
		}
		else if( pProperty->GetName() == "VERTICAL_SCROLLBAR" && pProperty->GetType()=="CGUIString")
		{
			SetVerticalScrollbar(pProperty->GetValue());
		}
		else if( pProperty->GetName() == "HORIZONAL_SCROLLBAR" && pProperty->GetType()=="CGUIString")
		{
			SetHorizonalScrollbar(pProperty->GetValue());
		}
	}
示例#2
0
//-----------------------------------------------------------------------------
// Purpose: 
// Input  : *parent - 
//			*panelName - 
//-----------------------------------------------------------------------------
CBaseHudChatLine::CBaseHudChatLine( vgui::Panel *parent, const char *panelName ) : 
	vgui::RichText( parent, panelName )
{
	m_hFont = m_hFontMarlett = 0;
	m_flExpireTime = 0.0f;
	m_flStartTime = 0.0f;
	m_iNameLength	= 0;

	SetPaintBackgroundEnabled( true );
	
	SetVerticalScrollbar( false );
}
//-----------------------------------------------------------------------------
// Purpose: 
// Input  : *parent - 
//			*panelName - 
//-----------------------------------------------------------------------------
CBaseHudChatLine::CBaseHudChatLine( vgui::Panel *parent, const char *panelName ) : 
	vgui::RichText( parent, panelName )
{
	m_hFont = m_hFontMarlett = 0;
	m_flExpireTime = 0.0f;
	m_flStartTime = 0.0f;
	m_iNameLength	= 0;
	m_text = NULL;

	SetPaintBackgroundEnabled( true );
	
	SetVerticalScrollbar( false );

#ifdef GE_DLL
	insertDefaultColors();
#endif
}