Esempio n. 1
0
 public Form1(PixelFarm.Drawing.GraphicsPlatform p)
 {
     InitializeComponent();
     this.uiPlatformWinForm = new LayoutFarm.UI.UIPlatformWinForm();
     LayoutFarm.UI.UIPlatform.CurrentUIPlatform = uiPlatformWinForm;
     this.gfxPlatform = p;
 }
Esempio n. 2
0
 public DevForm(PixelFarm.Drawing.GraphicsPlatform graphicsPlatform)
 {
     this.graphicsPlatform = graphicsPlatform;
     InitializeComponent();
     this.lstDemoList.DoubleClick += new EventHandler(lstDemoList_DoubleClick);
     LoadDemoList();
 }
Esempio n. 3
0
 public DevForm(PixelFarm.Drawing.GraphicsPlatform graphicsPlatform)
 {
     this.graphicsPlatform = graphicsPlatform;
     InitializeComponent();
     this.lstDemoList.DoubleClick += new EventHandler(lstDemoList_DoubleClick);
     LoadDemoList();
 }
Esempio n. 4
0
        /// <summary>
        /// Init.
        /// </summary>
        public DemoForm(PixelFarm.Drawing.GraphicsPlatform p)
        {
            this.graphicsPlatform = p;
            this._htmlPanel       = new LayoutFarm.Demo.HtmlPanel(this.graphicsPlatform, 800, 600);
            this.htmlHost         = new LayoutFarm.HtmlBoxes.HtmlHost(p);

            htmlHost.AttachEssentailHandlers(
                this.HandleImageRequest,
                this.HandleStylesheetRequest);
            _htmlPanel.SetHtmlHost(htmlHost);

            InitializeComponent();


            //_htmlToolTip.ImageLoad += OnImageLoad;
            //_htmlToolTip.SetToolTip(_htmlPanel, Resources.Tooltip);

            _htmlEditor.Font = new Font(FontFamily.GenericMonospace, 10);

            StartPosition = FormStartPosition.CenterScreen;
            var size = Screen.GetWorkingArea(Point.Empty);

            Size = new Size((int)(size.Width * 0.7), (int)(size.Height * 0.8));


            _updateHtmlTimer = new Timer(OnUpdateHtmlTimerTick);
            this.Text       += " : " + Path.GetDirectoryName(Application.ExecutablePath);

            this._samplesTreeView.NodeMouseClick += new TreeNodeMouseClickEventHandler(_samplesTreeView_NodeMouseClick);
        }
Esempio n. 5
0
        static FormDemoList()
        {

            var startPars = new LayoutFarm.UI.GdiPlus.MyWinGdiPortalSetupParameters();
            gdiPlatform = LayoutFarm.UI.GdiPlus.MyWinGdiPortal.Start(startPars);

            //-------------


            //-------------
        }
Esempio n. 6
0
        /// <summary>
        /// Creates a new HtmlPanel and sets a basic css for it's styling.
        /// </summary>
        public HtmlPanel(PixelFarm.Drawing.GraphicsPlatform p, int w, int h)
        {
            AutoScroll = true;
            BackColor  = SystemColors.Window;
            SetStyle(ControlStyles.ResizeRedraw, true);
            SetStyle(ControlStyles.SupportsTransparentBackColor, true);

            this.gfxPlatform  = p;
            this.renderCanvas = gfxPlatform.CreateCanvas(0, 0,
                                                         this.canvasW = w, this.canvasH = h);
        }
Esempio n. 7
0
        /// <summary>
        /// Init.
        /// </summary>
        public DemoForm(PixelFarm.Drawing.GraphicsPlatform p)
        {
            this.graphicsPlatform = p;
            this._htmlPanel = new LayoutFarm.Demo.HtmlPanel(this.graphicsPlatform, 800, 600);
            this.htmlHost = new LayoutFarm.HtmlBoxes.HtmlHost();
            htmlHost.AttachEssentailHandlers(
                this.HandleImageRequest,
                this.HandleStylesheetRequest);
            _htmlPanel.SetHtmlHost(htmlHost);
            InitializeComponent();
            //_htmlToolTip.ImageLoad += OnImageLoad; 
            //_htmlToolTip.SetToolTip(_htmlPanel, Resources.Tooltip);

            _htmlEditor.Font = new Font(FontFamily.GenericMonospace, 10);
            StartPosition = FormStartPosition.CenterScreen;
            var size = Screen.GetWorkingArea(Point.Empty);
            Size = new Size((int)(size.Width * 0.7), (int)(size.Height * 0.8));
            _updateHtmlTimer = new Timer(OnUpdateHtmlTimerTick);
            this.Text += " : " + Path.GetDirectoryName(Application.ExecutablePath);
            this._samplesTreeView.NodeMouseClick += new TreeNodeMouseClickEventHandler(_samplesTreeView_NodeMouseClick);
        }
Esempio n. 8
0
 public Form1(PixelFarm.Drawing.GraphicsPlatform p)
 {
     InitializeComponent();
     this.uiPlatformWinForm = new LayoutFarm.UI.UIPlatformWinForm();
     this.gfxPlatform       = p;
 }
Esempio n. 9
0
 /// <summary>
 /// Creates a new HtmlPanel and sets a basic css for it's styling.
 /// </summary>
 public HtmlPanel(PixelFarm.Drawing.GraphicsPlatform p, int w, int h)
 {
     AutoScroll = true;
     BackColor = SystemColors.Window;
     SetStyle(ControlStyles.ResizeRedraw, true);
     SetStyle(ControlStyles.SupportsTransparentBackColor, true);
     this.gfxPlatform = p;
     
     this.renderCanvas = gfxPlatform.CreateCanvas(0, 0,
         this.canvasW = w, this.canvasH = h);
 }