29 #include YFM_Helper_ShellHelper
37 : event_info(str), base_tick()
39 std::printf(
"Start tick of [%s] :\n",
event_info.c_str());
47 std::printf(
"Performed [%s] in: %f milliseconds.\n",
58 app.AccessQueue([&](MessageQueue& mq){
59 return mq.Remove(app.UIResponseLimit);
69 snftime(
char* buf,
size_t ,
const std::tm& tm,
76 std::sprintf(buf,
format, tm.tm_year + 1900,
77 tm.tm_mon, tm.tm_mday, tm.tm_hour, tm.tm_min, tm.tm_sec);
90 snftime(str, 80, tm, format);
96 auto p(std::localtime(&t));
100 " @ TranslateTime#2;");
105 shared_ptr<UI::TextList::ListType>
110 return ystdex::make_shared<UI::TextList::ListType>(mFamilies.cbegin()
158 shared_ptr<TextList::ListType>
162 auto p_list(ystdex::make_shared<TextList::ListType>(styles.cbegin()
165 YAssert(
bool(p_list) && !p_list->empty(),
166 "Invalid style mapping state found");
167 p_list->front() = std::move(default_name);
168 return ystdex::make_shared<TextList::ListType>(p_list->cbegin(),
size_t refresh_count
刷新计数。
YF_API GUIState & FetchGUIState()
取默认图形用户界面公共状态。
YF_API void Invalidate(IWidget &, const Rect &)
无效化:使相对于部件的指定区域在直接和间接的窗口缓冲区中无效。
static time_point now() ynothrow
YF_API const char * TranslateTime(const std::tm &, const char *=DefaultTimeFormat)
格式化时间字符串。
std::chrono::nanoseconds last_tick
内部计数。
_tApp & FetchGlobalInstance() ynothrow
YF_API shared_ptr< UI::TextList::ListType > FetchFontFamilyNames()
取字型家族名称。
yconstexpr const char * DefaultTimeFormat("%04u-%02u-%02u %02u:%02u:%02u")
默认时间格式字符串。
std::runtime_error GeneralEvent
一般运行时异常事件类。
#define YB_UNLIKELY(expr)
分支预测提示。
YSLib 标准字符串(使用 UCS-2 作为内部编码)。
now_tick size_t Refresh()
刷新:更新计数器内部计数。
YF_API void RemoveGlobalTasks()
从全局消息队列中移除所有后台消息。
YF_API void SwitchVisible(IWidget &)
切换部件显示状态并无效化。
YF_API std::uint64_t GetHighResolutionTicks()
取高精度 tick 数。
YF_API Drawing::FontCache & FetchDefaultFontCache()
取默认字体缓存。
GSStringTemplate< char >::basic_string string
#define ythrow(...)
YSLib 动态异常规范:根据是否使用异常规范宏指定或忽略动态异常规范。
std::chrono::nanoseconds MinimalInterval
计时间隔下界。
YF_API void SwitchVisibleToFront(IWidget &)
切换部件显示状态并请求提升至前端。
std::chrono::nanoseconds now_tick
Timers::HighResolutionClock::time_point base_tick
DebugTimer(const std::string &str="")
YF_API void RequestToFront(IWidget &)
请求提升至容器前端。
YF_API shared_ptr< TextList::ListType > FetchVisualStyleNames(String=u"<Default>")
取视觉样式名称。
FPSCounter(std::chrono::nanoseconds={})
构造:使用指定计时间隔下界。
#define YAssert(_expr, _msg)