Esempio n. 1
0
        private void InitializeDrawElements(GuiSystem guiSystem)
        {
            var itemDescriptor = guiSystem.GetSkinItemDescriptor <ButtonSkinItemDescriptor>();

            _normalSprite = new NinePatchSprite(itemDescriptor.SkinTexture, itemDescriptor.NormalRectangle, itemDescriptor.ButtonBorder);
            _hoverSprite  = new NinePatchSprite(itemDescriptor.SkinTexture, itemDescriptor.HoverRectangle, itemDescriptor.ButtonBorder);
        }
Esempio n. 2
0
        private void InitializeDrawElements(GuiSystem guiSystem)
        {
            var itemDescriptor = guiSystem.GetSkinItemDescriptor <FrameSkinItemDescriptor>();

            _headerFont    = itemDescriptor.BigFont;
            _contentBorder = new NinePatchSprite(itemDescriptor.SkinTexture, itemDescriptor.SourceRectangle, itemDescriptor.FrameBorder);
            _headerBorder  = new NinePatchSprite(itemDescriptor.SkinTexture, itemDescriptor.SourceRectangle, itemDescriptor.FrameBorder);
        }
Esempio n. 3
0
        private void InitializeDrawElements()
        {
            var descriptor = GuiSystem.GetSkinItemDescriptor <TextBlockSkinItemDescriptor>();

            _spriteText = new SpriteText(descriptor.NormalFont);

            _spriteText.HorizontalAlignment = HorizontalAlignment;
            _spriteText.VerticalAlignment   = VerticalAlignment;
        }
Esempio n. 4
0
        private void InitializeDrawElements()
        {
            var itemDescriptor = GuiSystem.GetSkinItemDescriptor <TextBoxSkinItemDescriptor>();

            _border = new NinePatchSprite(itemDescriptor.SkinTexture, itemDescriptor.NormalRectangle, itemDescriptor.Border);

            _spriteText = new SpriteText(itemDescriptor.NormalFont);
            _spriteText.HorizontalAlignment = HorizontalAlignment.Left;

            _cursorAnimatorTimer = new ActionTimer(OnCursorAnimateTick, 0.5f, true);
            _cursorAnimatorTimer.Start();

            _inputController = new StringInputController(InputType.AlphaNumeric);
        }