DDraceNetwork Docs
CScrollRegion Class Reference

#include <ui_scrollregion.h>

Inheritance diagram for CScrollRegion:
[legend]
Collaboration diagram for CScrollRegion:
[legend]

Public Types

enum  EScrollRelative { SCROLLRELATIVE_UP = -1 , SCROLLRELATIVE_NONE = 0 , SCROLLRELATIVE_DOWN = 1 }
 
enum  EScrollOption { SCROLLHERE_KEEP_IN_VIEW = 0 , SCROLLHERE_TOP , SCROLLHERE_BOTTOM }
 

Public Member Functions

 CScrollRegion ()
 
void Begin (CUIRect *pClipRect, vec2 *pOutOffset, const CScrollRegionParams *pParams=nullptr)
 
void End ()
 
bool AddRect (const CUIRect &Rect, bool ShouldScrollHere=false)
 
void ScrollHere (EScrollOption Option=SCROLLHERE_KEEP_IN_VIEW)
 
void ScrollRelative (EScrollRelative Direction, float SpeedMultiplier=1.0f)
 
void ScrollRelativeDirect (float ScrollAmount)
 
const CUIRectClipRect () const
 
void DoEdgeScrolling ()
 
bool RectClipped (const CUIRect &Rect) const
 
bool ScrollbarShown () const
 
bool Animating () const
 
bool Active () const
 
const CScrollRegionParamsParams () const
 

Static Public Attributes

static constexpr float HEIGHT_MAGIC_FIX = 1.0f
 

Private Attributes

float m_ScrollY
 
float m_ContentH
 
float m_RequestScrollY
 
EScrollRelative m_ScrollDirection
 
float m_ScrollSpeedMultiplier
 
float m_AnimTimeMax
 
float m_AnimTime
 
float m_AnimInitScrollY
 
float m_AnimTargetScrollY
 
CUIRect m_ClipRect
 
CUIRect m_RailRect
 
CUIRect m_LastAddedRect
 
float m_SliderGrabPos
 
vec2 m_ContentScrollOff
 
CScrollRegionParams m_Params
 

Additional Inherited Members

- Private Member Functions inherited from CUIElementBase
IClientClient () const
 
IGraphicsGraphics () const
 
IInputInput () const
 
ITextRenderTextRender () const
 
CUiUi () const
 
- Static Private Member Functions inherited from CUIElementBase
static void Init (CUi *pUI)
 

Member Enumeration Documentation

◆ EScrollOption

Enumerator
SCROLLHERE_KEEP_IN_VIEW 
SCROLLHERE_TOP 
SCROLLHERE_BOTTOM 

◆ EScrollRelative

Enumerator
SCROLLRELATIVE_UP 
SCROLLRELATIVE_NONE 
SCROLLRELATIVE_DOWN 

Constructor & Destructor Documentation

◆ CScrollRegion()

CScrollRegion::CScrollRegion ( )

Member Function Documentation

◆ Active()

bool CScrollRegion::Active ( ) const

◆ AddRect()

bool CScrollRegion::AddRect ( const CUIRect Rect,
bool  ShouldScrollHere = false 
)

◆ Animating()

bool CScrollRegion::Animating ( ) const

◆ Begin()

void CScrollRegion::Begin ( CUIRect pClipRect,
vec2 pOutOffset,
const CScrollRegionParams pParams = nullptr 
)

◆ ClipRect()

const CUIRect * CScrollRegion::ClipRect ( ) const
inline

◆ DoEdgeScrolling()

void CScrollRegion::DoEdgeScrolling ( )

◆ End()

void CScrollRegion::End ( )

◆ Params()

const CScrollRegionParams & CScrollRegion::Params ( ) const
inline

◆ RectClipped()

bool CScrollRegion::RectClipped ( const CUIRect Rect) const

◆ ScrollbarShown()

bool CScrollRegion::ScrollbarShown ( ) const

◆ ScrollHere()

void CScrollRegion::ScrollHere ( EScrollOption  Option = SCROLLHERE_KEEP_IN_VIEW)

◆ ScrollRelative()

void CScrollRegion::ScrollRelative ( EScrollRelative  Direction,
float  SpeedMultiplier = 1.0f 
)

◆ ScrollRelativeDirect()

void CScrollRegion::ScrollRelativeDirect ( float  ScrollAmount)

Member Data Documentation

◆ HEIGHT_MAGIC_FIX

constexpr float CScrollRegion::HEIGHT_MAGIC_FIX = 1.0f
staticconstexpr

◆ m_AnimInitScrollY

float CScrollRegion::m_AnimInitScrollY
private

◆ m_AnimTargetScrollY

float CScrollRegion::m_AnimTargetScrollY
private

◆ m_AnimTime

float CScrollRegion::m_AnimTime
private

◆ m_AnimTimeMax

float CScrollRegion::m_AnimTimeMax
private

◆ m_ClipRect

CUIRect CScrollRegion::m_ClipRect
private

◆ m_ContentH

float CScrollRegion::m_ContentH
private

◆ m_ContentScrollOff

vec2 CScrollRegion::m_ContentScrollOff
private

◆ m_LastAddedRect

CUIRect CScrollRegion::m_LastAddedRect
private

◆ m_Params

CScrollRegionParams CScrollRegion::m_Params
private

◆ m_RailRect

CUIRect CScrollRegion::m_RailRect
private

◆ m_RequestScrollY

float CScrollRegion::m_RequestScrollY
private

◆ m_ScrollDirection

EScrollRelative CScrollRegion::m_ScrollDirection
private

◆ m_ScrollSpeedMultiplier

float CScrollRegion::m_ScrollSpeedMultiplier
private

◆ m_ScrollY

float CScrollRegion::m_ScrollY
private

◆ m_SliderGrabPos

float CScrollRegion::m_SliderGrabPos
private

The documentation for this class was generated from the following files: