protected virtual void OnTvFontsMeasureItem(object sender, HollyLibrary.MeasureItemEventArgs args) { args.ItemHeight = 25; }
protected virtual void OnFolderTreeBeforeNodeExpand(object sender, HollyLibrary.NodeEventArgs args) { HTreeNode node = args.Node; String path = getPathFromNode(node); buildNode ( node ); //select the expanded node FolderTree.selectNode( node ); ChangeFatherPath ( path ); }
protected virtual void OnTvFontsDrawItem(object sender, HollyLibrary.DrawItemEventArgs args) { //draw each font String font_name = TvFonts.Items[ args.ItemIndex ].ToString(); Pango.Layout l = new Pango.Layout( this.PangoContext ); l.SetText( font_name ); l.FontDescription = Pango.FontDescription.FromString( font_name ); int width, height; l.GetPixelSize( out width, out height ); args.Drawable.DrawLayout( this.Style.TextGC( this.State ) , args.CellArea.X, args.CellArea.Y + (height/2), l ); }
protected virtual void OnGtkcontrol1MouseWheel(object sender, HollyLibrary.GcMouseEventArgs args) { HollyLibrary.GcMouseEventArgs a = args; Console.WriteLine( "mouse wheel!" + a.Delta ); }
protected virtual void OnGtkcontrol1MouseUp(object sender, HollyLibrary.GcMouseEventArgs args) { HollyLibrary.GcMouseEventArgs a = args; Console.WriteLine( "mouse up!" + a.Button ); }
protected virtual void OnGtkcontrol1MouseMove(object sender, HollyLibrary.GcMouseEventArgs args) { Console.WriteLine( "mouse move!"); }
protected virtual void OnGtkcontrol1MouseDoubleClick(object sender, HollyLibrary.GcMouseEventArgs args) { HollyLibrary.GcMouseEventArgs a = args; Console.WriteLine( "mouse dbl click!" + a.Button ); gtkcontrol1.BackColor = GraphUtil.gdkColorFromWinForms( System.Drawing.Color.AliceBlue ); }
protected virtual void OnGtkcontrol1KeyUp(object sender, HollyLibrary.GcKeyEventArgs args) { HollyLibrary.GcKeyEventArgs a = args; a.SuppressKeyPress = true; Console.WriteLine("Key down: " + a.KeyCode + " alt:" + a.Alt + " ctrl:" + a.Control+ " shift:" + a.Shift ); }