载入中...
搜索中...
未找到
eve::ui::PcgTooltipManager类 参考

Caller-owned runtime model of Pcg Tooltip, TooltipManager, Profile and Trigger. 更多...

#include <PcgTooltip.h>

Public 成员函数

Result< void > configure (int interactionMode, int theme, float delay, float bottomOffset, float topOffset, int wrapLimit)
 Configure interaction mode (0 UI, 1 scene, 2 both), theme (0 light, 1 dark), delay and layout.
 
Result< void > addTooltip (const std::string &id, const std::string &header, const std::string &text)
 Append a tooltip profile entry.
 
Result< bool > removeTooltip (const std::string &query)
 Remove first entry whose id contains the query.
 
Result< bool > enter (int source, const std::string &query, float now)
 Schedule the first profile entry whose id contains query. source is 0 UI or 1 scene.
 
Result< void > enterText (int source, const std::string &content, const std::string &header, float now)
 Schedule direct trigger content, matching TooltipTrigger.
 
Result< void > exit (int source)
 Cancel matching hover and hide tooltip.
 
Result< void > tick (float now, float mouseX, float mouseY, float screenWidth, float screenHeight, bool anyInput)
 Update mouse placement, delayed visibility, and input dismissal.
 
void hide () noexcept
 Hide and cancel all pending tooltip work.
 
bool getVisible () const noexcept
 Return visible state.
 
bool getPending () const noexcept
 Return pending-delay state.
 
const std::string & getHeader () const noexcept
 Return active header.
 
const std::string & getText () const noexcept
 Return active content.
 
bool getHeaderVisible () const noexcept
 Return whether header should be shown.
 
bool getWrapEnabled () const noexcept
 Return whether layout wrapping is enabled.
 
float getPivotX () const noexcept
 Return pointer pivot X.
 
float getPivotY () const noexcept
 Return pointer pivot Y.
 
float getBackgroundR () const noexcept
 Return background red for active theme.
 
float getForeground () const noexcept
 Return foreground intensity for active theme.
 
int getCount () const noexcept
 Return profile row count.
 

详细描述

Caller-owned runtime model of Pcg Tooltip, TooltipManager, Profile and Trigger.

在文件 PcgTooltip.h 第 12 行定义.

成员函数说明

◆ addTooltip()

Result< void > eve::ui::PcgTooltipManager::addTooltip ( const std::string &  id,
const std::string &  header,
const std::string &  text 
)

Append a tooltip profile entry.

在文件 PcgTooltip.cpp 第 7 行定义.

引用了 eve::Diagnostic::error(), eve::Result< T >::failure(), id, eve::InvalidArgument, eve::Result< T >::success() , 以及 text.

◆ configure()

Result< void > eve::ui::PcgTooltipManager::configure ( int  interactionMode,
int  theme,
float  delay,
float  bottomOffset,
float  topOffset,
int  wrapLimit 
)

Configure interaction mode (0 UI, 1 scene, 2 both), theme (0 light, 1 dark), delay and layout.

在文件 PcgTooltip.cpp 第 6 行定义.

引用了 bottom, eve::Diagnostic::error(), eve::Result< T >::failure(), hide(), eve::InvalidArgument, eve::Result< T >::success(), theme , 以及 top.

◆ enter()

Result< bool > eve::ui::PcgTooltipManager::enter ( int  source,
const std::string &  query,
float  now 
)

Schedule the first profile entry whose id contains query. source is 0 UI or 1 scene.

在文件 PcgTooltip.cpp 第 10 行定义.

引用了 accepts, eve::Diagnostic::error(), eve::Result< T >::failure(), eve::InvalidArgument, q, source , 以及 eve::Result< T >::success().

◆ enterText()

Result< void > eve::ui::PcgTooltipManager::enterText ( int  source,
const std::string &  content,
const std::string &  header,
float  now 
)

Schedule direct trigger content, matching TooltipTrigger.

在文件 PcgTooltip.cpp 第 11 行定义.

引用了 accepts, eve::Diagnostic::error(), eve::Result< T >::failure(), eve::InvalidArgument, source , 以及 eve::Result< T >::success().

◆ exit()

Result< void > eve::ui::PcgTooltipManager::exit ( int  source)

Cancel matching hover and hide tooltip.

在文件 PcgTooltip.cpp 第 12 行定义.

引用了 accepts, eve::Diagnostic::error(), eve::Result< T >::failure(), eve::InvalidArgument, source , 以及 eve::Result< T >::success().

◆ getBackgroundR()

float eve::ui::PcgTooltipManager::getBackgroundR ( ) const
inlinenoexcept

Return background red for active theme.

在文件 PcgTooltip.h 第 30 行定义.

◆ getCount()

int eve::ui::PcgTooltipManager::getCount ( ) const
inlinenoexcept

Return profile row count.

在文件 PcgTooltip.h 第 32 行定义.

◆ getForeground()

float eve::ui::PcgTooltipManager::getForeground ( ) const
inlinenoexcept

Return foreground intensity for active theme.

在文件 PcgTooltip.h 第 31 行定义.

◆ getHeader()

const std::string & eve::ui::PcgTooltipManager::getHeader ( ) const
inlinenoexcept

Return active header.

在文件 PcgTooltip.h 第 24 行定义.

◆ getHeaderVisible()

bool eve::ui::PcgTooltipManager::getHeaderVisible ( ) const
inlinenoexcept

Return whether header should be shown.

在文件 PcgTooltip.h 第 26 行定义.

◆ getPending()

bool eve::ui::PcgTooltipManager::getPending ( ) const
inlinenoexcept

Return pending-delay state.

在文件 PcgTooltip.h 第 23 行定义.

◆ getPivotX()

float eve::ui::PcgTooltipManager::getPivotX ( ) const
inlinenoexcept

Return pointer pivot X.

在文件 PcgTooltip.h 第 28 行定义.

◆ getPivotY()

float eve::ui::PcgTooltipManager::getPivotY ( ) const
inlinenoexcept

Return pointer pivot Y.

在文件 PcgTooltip.h 第 29 行定义.

◆ getText()

const std::string & eve::ui::PcgTooltipManager::getText ( ) const
inlinenoexcept

Return active content.

在文件 PcgTooltip.h 第 25 行定义.

◆ getVisible()

bool eve::ui::PcgTooltipManager::getVisible ( ) const
inlinenoexcept

Return visible state.

在文件 PcgTooltip.h 第 22 行定义.

◆ getWrapEnabled()

bool eve::ui::PcgTooltipManager::getWrapEnabled ( ) const
inlinenoexcept

Return whether layout wrapping is enabled.

在文件 PcgTooltip.h 第 27 行定义.

◆ hide()

void eve::ui::PcgTooltipManager::hide ( )
inlinenoexcept

Hide and cancel all pending tooltip work.

在文件 PcgTooltip.h 第 21 行定义.

被这些函数引用 configure() , 以及 tick().

◆ removeTooltip()

Result< bool > eve::ui::PcgTooltipManager::removeTooltip ( const std::string &  query)

Remove first entry whose id contains the query.

在文件 PcgTooltip.cpp 第 8 行定义.

引用了 eve::Diagnostic::error(), eve::Result< T >::failure(), eve::InvalidArgument, q , 以及 eve::Result< T >::success().

◆ tick()

Result< void > eve::ui::PcgTooltipManager::tick ( float  now,
float  mouseX,
float  mouseY,
float  screenWidth,
float  screenHeight,
bool  anyInput 
)

Update mouse placement, delayed visibility, and input dismissal.

在文件 PcgTooltip.cpp 第 13 行定义.

引用了 eve::Diagnostic::error(), eve::Result< T >::failure(), hide(), input, eve::InvalidArgument, eve::Result< T >::success(), x , 以及 y.


该类的文档由以下文件生成: