Skip to content

Commit

Permalink
Pixi: Removed unused "small" font
Browse files Browse the repository at this point in the history
  • Loading branch information
foxnne committed Jan 9, 2025
1 parent 79b1924 commit 9ef175b
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 11 deletions.
4 changes: 0 additions & 4 deletions src/Pixi.zig
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,6 @@ pub const Sidebar = enum(u32) {
pub const Fonts = struct {
fa_standard_regular: *imgui.Font = undefined,
fa_standard_solid: *imgui.Font = undefined,
fa_small_regular: *imgui.Font = undefined,
fa_small_solid: *imgui.Font = undefined,
};

pub fn init(_app: *App, _core: *Core, app_mod: mach.Mod(App), _editor: *Editor) !void {
Expand Down Expand Up @@ -234,8 +232,6 @@ pub fn lateInit(editor_mod: mach.Mod(Editor)) !void {

app.fonts.fa_standard_solid = io.fonts.?.addFontFromFileTTF(assets.root ++ "fonts/fa-solid-900.ttf", app.settings.font_size * scale_factor, &fa_config, @ptrCast(ranges.ptr)).?;
app.fonts.fa_standard_regular = io.fonts.?.addFontFromFileTTF(assets.root ++ "fonts/fa-regular-400.ttf", app.settings.font_size * scale_factor, &fa_config, @ptrCast(ranges.ptr)).?;
app.fonts.fa_small_solid = io.fonts.?.addFontFromFileTTF(assets.root ++ "fonts/fa-solid-900.ttf", 10 * scale_factor, &fa_config, @ptrCast(ranges.ptr)).?;
app.fonts.fa_small_regular = io.fonts.?.addFontFromFileTTF(assets.root ++ "fonts/fa-regular-400.ttf", 10 * scale_factor, &fa_config, @ptrCast(ranges.ptr)).?;

// Initialize the editor which loads our theme
editor_mod.call(.init);
Expand Down
7 changes: 0 additions & 7 deletions src/editor/explorer/layers.zig
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,6 @@ pub fn draw() !void {
imgui.pushStyleColorImVec4(imgui.Col_ButtonHovered, Pixi.editor.theme.foreground.toImguiVec4());
defer imgui.popStyleColorEx(3);

imgui.pushFont(Pixi.app.fonts.fa_small_regular);
imgui.pushFont(Pixi.app.fonts.fa_small_solid);
defer {
imgui.popFont();
imgui.popFont();
}

if (file.heightmap.layer != null) {
imgui.pushStyleVarImVec2(imgui.StyleVar_FramePadding, .{ .x = 6.0, .y = 5.0 });
defer imgui.popStyleVar();
Expand Down

0 comments on commit 9ef175b

Please sign in to comment.