コード例 #1
0
ファイル: WinGui.cs プロジェクト: luca-cardelli/KaemikaXM
 private void GuiToWin_KeyUp(object sender, KeyEventArgs e)
 {
     if (e.KeyCode == Keys.ShiftKey)
     {
         shiftKeyDown = false; KChartSKControl.OnShiftKeyUp();
     }
 }
コード例 #2
0
        public KChartSKControl() : base()
        {
            chartControl          = this;
            chartControl.Location = new Point(0, 0);
            Label toolTip = WinGui.winGui.label_Tooltip;

            toolTip.Visible     = false;
            toolTip.BackColor   = WinControls.cPanelButtonDeselected;
            toolTip.Font        = WinGui.winGui.GetFont(8, true);
            toolTip.MouseEnter +=
                (object sender, EventArgs e) => { UpdateTooltip(new Point(0, 0), ""); };

            /* Initialize Interface KTouchClient with a locally-sourced KTouchClientData closure */
            touch = new KTouchClientData(
                invalidateSurface: () => { InvalidateAndUpdate(); },
                setManualPinchPan: (Swipe pinchPan) => { KChartHandler.SetManualPinchPan(pinchPan); }
                );
            touch.onTouchSwipeOrMouseDrag      = OnMouseDrag;
            touch.onTouchSwipeOrMouseDragEnd   = OnMouseDragEnd;
            touch.onTouchDoubletapOrMouseClick = OnMouseClick;
            touch.onTouchPinchOrMouseZoom      = OnMouseZoom;
            touch.lastPinchPan           = Swipe.Id();
            touch.incrementalScaling     = Swipe.Id();
            touch.incrementalTranslation = Swipe.Id();
            KChartHandler.RegisterKTouchClientData(touch);
        }
コード例 #3
0
ファイル: WinGui.cs プロジェクト: luca-cardelli/KaemikaXM
 public /* Interface KGuiControl */ void GuiChartUpdate()
 {
     if (!this.InvokeRequired)
     {
         KChartHandler.VisibilityRestore(); // this is needed to hide the series in the chart
         KChartSKControl.SetSize(panel_KChart.Size);
         KChartSKControl.InvalidateAndUpdate();
     }
     else
     {
         this.Invoke((Action) delegate { GuiChartUpdate(); });
     }
 }
コード例 #4
0
ファイル: WinGui.cs プロジェクト: luca-cardelli/KaemikaXM
 private void panel_KChart_SizeChanged(object sender, EventArgs e)
 {
     KChartSKControl.SetSize(this.panel_KChart.Size);
 }