("[^"]+"|[^\\s"]+)RegexOptions.Compiled
○ 1st capture group.
○ Match with 2 alternative expressions, atomically.
○ Match a sequence of expressions.
○ Match '"'.
○ Match a character other than '"' atomically at least once.
○ Match '"'.
○ Match a character in the set [^"\s] atomically at least once.
[^a-z]
○ Match a character in the set [^a-z].
(http|ftp|https)://([\\w_-]+(?:(?:\\.[\\w_-]+)+))([\\w.,@?^=%&:/~+#-]*[\\w@?^=%&/~+#-])?RegexOptions.Compiled
○ 1st capture group.
○ Match with 3 alternative expressions.
○ Match the string "http".
○ Match the string "ftp".
○ Match the string "https".
○ Match the string "://".
○ 2nd capture group.
○ Match a character in the set [-_\w] atomically at least once.
○ Loop greedily at least once.
○ Match '.'.
○ Match a character in the set [-_\w] greedily at least once.
○ Optional (greedy).
○ 3rd capture group.
○ Match a character in the set [#%&+-/:=?@^~\w] greedily any number of times.
○ Match a character in the set [#%&+-/=?@^~\w].
using (atlas.SuppressBuild()) {
this.font1 = atlas.NewGameFontHandle(...);
this.font2 = atlas.NewDelegateFontHandle(...);
}
this.fontHandle = atlas.NewDelegateFontHandle(e => e.OnPreBuild(tk => {
var config = new SafeFontConfig { SizePx = UiBuilder.DefaultFontSizePx };
config.MergeFont = tk.AddFontFromFile(@"C:\Windows\Fonts\comic.ttf", config);
tk.AddGameSymbol(config);
tk.AddExtraGlyphsForDalamudLanguage(config);
// optionally do the following if you have to add more than one font here,
// to specify which font added during this delegate is the final font to use.
tk.Font = config.MergeFont;
}));
// or
this.fontHandle = atlas.NewDelegateFontHandle(e => e.OnPreBuild(tk => tk.AddDalamudDefaultFont(36)));
using (this.fontHandle.Push())
ImGui.TextUnformatted("Example");
using (fontHandle.Push())
ImGui.TextUnformatted("Test");
Push a font with a matching call to
fontHandle.Push();
ImGui.TextUnformatted("Test 2");
fontHandle.Pop();
Push a font between two choices.
using ((someCondition ? myFontHandle : dalamudPluginInterface.UiBuilder.MonoFontHandle).Push())
ImGui.TextUnformatted("Test 3");
fontAtlas.NewDelegateFontHandle(
e => e.OnPreBuild(
tk => tk.AddDalamudDefaultFont(UiBuilder.DefaultFontSizePx)));
fontAtlas.NewDelegateFontHandle(
e => e.OnPreBuild(
tk => tk.AddFontAwesomeIconFont(new() { SizePt = UiBuilder.DefaultFontSizePt })));
// or use
tk => tk.AddFontAwesomeIconFont(new() { SizePx = UiBuilder.DefaultFontSizePx })));
fontAtlas.NewDelegateFontHandle(
e => e.OnPreBuild(
tk => tk.AddDalamudAssetFont(
DalamudAsset.InconsolataRegular,
new() { SizePt = UiBuilder.DefaultFontSizePt })));
// or use
new() { SizePx = UiBuilder.DefaultFontSizePx })));
fontAtlas.NewDelegateFontHandle(
e => e.OnPreBuild(
tk => tk.AddDalamudDefaultFont(UiBuilder.DefaultFontSizePx)));
fontAtlas.NewDelegateFontHandle(
e => e.OnPreBuild(
tk => tk.AddFontAwesomeIconFont(new() { SizePt = UiBuilder.DefaultFontSizePt })));
// or use
tk => tk.AddFontAwesomeIconFont(new() { SizePx = UiBuilder.DefaultFontSizePx })));
fontAtlas.NewDelegateFontHandle(
e => e.OnPreBuild(
tk => tk.AddDalamudAssetFont(
DalamudAsset.InconsolataRegular,
new() { SizePt = UiBuilder.DefaultFontSizePt })));
// or use
new() { SizePx = UiBuilder.DefaultFontSizePx })));
var task = TaskThrowingException();
task.SuppressException();
await TaskThrowingException(); // This line will throw.
await TaskThrowingException().SuppressException();
TaskThrowingException().SuppressException();