コード例 #1
0
ファイル: Form1.cs プロジェクト: prepare/HTML-Renderer
 public Form1(PixelFarm.Drawing.GraphicsPlatform p)
 {
     InitializeComponent();
     this.uiPlatformWinForm = new LayoutFarm.UI.UIPlatformWinForm();
     LayoutFarm.UI.UIPlatform.CurrentUIPlatform = uiPlatformWinForm;
     this.gfxPlatform = p;
 }
コード例 #2
0
 public DevForm(PixelFarm.Drawing.GraphicsPlatform graphicsPlatform)
 {
     this.graphicsPlatform = graphicsPlatform;
     InitializeComponent();
     this.lstDemoList.DoubleClick += new EventHandler(lstDemoList_DoubleClick);
     LoadDemoList();
 }
コード例 #3
0
ファイル: DevForm.cs プロジェクト: prepare/HTML-Renderer
 public DevForm(PixelFarm.Drawing.GraphicsPlatform graphicsPlatform)
 {
     this.graphicsPlatform = graphicsPlatform;
     InitializeComponent();
     this.lstDemoList.DoubleClick += new EventHandler(lstDemoList_DoubleClick);
     LoadDemoList();
 }
コード例 #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);
        }
コード例 #5
0
ファイル: FormDemoList.cs プロジェクト: prepare/HTML-Renderer
        static FormDemoList()
        {

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

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


            //-------------
        }
コード例 #6
0
ファイル: HtmlPanel.cs プロジェクト: asmboom/HtmlRenderer
        /// <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);
        }
コード例 #7
0
ファイル: DemoForm.cs プロジェクト: prepare/HTML-Renderer
        /// <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);
        }
コード例 #8
0
ファイル: Form1.cs プロジェクト: asmboom/HtmlRenderer
 public Form1(PixelFarm.Drawing.GraphicsPlatform p)
 {
     InitializeComponent();
     this.uiPlatformWinForm = new LayoutFarm.UI.UIPlatformWinForm();
     this.gfxPlatform       = p;
 }
コード例 #9
0
ファイル: HtmlPanel.cs プロジェクト: prepare/HTML-Renderer
 /// <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);
 }