using Avalonia;
using Avalonia.Controls;
using Avalonia.Media;

namespace PixiEditor.UI.Common.Fonts;

//TODO: Make autogenerated from PixiPerfectIcons.axaml
public static class PixiPerfectIcons
{
    public const string AddReference = "\ue900";
    public const string AddToMask = "\ue901";
    public const string AlphaLock = "\ue902";
    public const string AlphaUnlock = "\ue903";
    public const string ArrowDown = "\ue904";
    public const string ArrowLeft = "\ue905";
    public const string ArrowRight = "\ue906";
    public const string ArrowUp = "\ue907";
    public const string Book = "\ue908";
    public const string Bucket = "\ue909";
    public const string CanvasResize = "\ue90a";
    public const string Center = "\ue90b";
    public const string ChevronDown = "\ue90c";
    public const string ChevronLeft = "\ue90d";
    public const string ChevronRight = "\ue90e";
    public const string ChevronUp = "\ue90f";
    public const string Circle = "\ue910";
    public const string Clock = "\ue911";
    public const string ColorPalette = "\ue912";
    public const string ColorPicker = "\ue913";
    public const string ColorSliders = "\ue914";
    public const string ColorsSwap = "\ue915";
    public const string Compass = "\ue916";
    public const string Copy = "\ue917";
    public const string CornerUpLeft = "\ue918";
    public const string CornerUpRight = "\ue919";
    public const string CreateMask = "\ue91a";
    public const string CropToSelection = "\ue91b";
    public const string Crop = "\ue91c";
    public const string Database = "\ue91d";
    public const string Deselect = "\ue91e";
    public const string Droplet = "\ue91f";
    public const string DuplicateFile = "\ue920";
    public const string Duplicate = "\ue921";
    public const string Edit = "\ue922";
    public const string Exit = "\ue923";
    public const string EyeOff = "\ue924";
    public const string Eye = "\ue925";
    public const string FileMinus90 = "\ue926";
    public const string FilePlus = "\ue927";
    public const string FileText = "\ue928";
    public const string File = "\ue929";
    public const string File90 = "\ue92a";
    public const string File180 = "\ue92b";

    public const string FolderPlus = "\ue92c";
    public const string Folder = "\ue92d";
    public const string Globe = "\ue92e";
    public const string Grid = "\ue92f";
    public const string Home = "\ue930";
    public const string ImageMinus90 = "\ue931";
    public const string Image = "\ue932";
    public const string Image90 = "\ue933";
    public const string Image180 = "\ue934";
    public const string Info = "\ue935";
    public const string Intersect = "\ue936";
    public const string Invert = "\ue937";
    public const string Lasso = "\ue938";
    public const string Layers = "\ue939";
    public const string Line = "\ue93a";
    public const string Lock = "\uE93B";
    public const string LogOut = "\uE93C";
    public const string MagicWand = "\uE93D";
    public const string Minimize2 = "\uE93E";
    public const string Minimize = "\uE93F";
    public const string MousePointer = "\uE940";
    public const string MoveView = "\uE942";
    public const string NewMask = "\uE943";
    public const string Paste = "\uE944";
    public const string VectorPen = "\uE945";
    public const string Picker = "\uE946";
    public const string PlusSquare = "\uE947";
    public const string RectangleSelection = "\uE948";
    public const string Redo = "\uE949";
    public const string ReferenceLayer = "\uE94A";
    public const string Resize = "\uE94B";
    public const string RotateView = "\uE94C";
    public const string Eraser = "\uE94D";
    public const string Save = "\uE94E";
    public const string Scissors = "\uE94F";
    public const string SelectAll = "\uE950";
    public const string Settings = "\uE951";
    public const string Sliders = "\uE952";
    public const string Square = "\uE953";
    public const string Subtract = "\uE954";
    public const string Sun = "\uE955";
    public const string Swap = "\uE956";
    public const string Tool = "\uE957";
    public const string Trash = "\uE958";
    public const string Undo = "\uE959";
    public const string Unlock = "\uE95A";
    public const string XFlip = "\uE95B";
    public const string XSelectedFlip = "\uE95C";
    public const string XSymmetry = "\uE95D";
    public const string YFlip = "\uE95E";
    public const string YSelectedFlip = "\uE95F";
    public const string YSymmetry = "\uE960";
    public const string ZoomIn = "\uE961";
    public const string ZoomOut = "\uE962";

    public static TextBlock ToIconControl(string unicode)
    {
        return new TextBlock()
        {
            Text = unicode,
            FontFamily = Application.Current.Styles.TryGetResource("PixiPerfectIcons", null, out var font) ? font as FontFamily : null,
            FontSize = 16,
            VerticalAlignment = Avalonia.Layout.VerticalAlignment.Center,
            HorizontalAlignment = Avalonia.Layout.HorizontalAlignment.Center
        };
    }
}
