64 |
ImageSize property on 32 (specifies the size of the control' icons)
|
63 |
ImageSize property on 16 (default) (specifies the size of the control' icons)
|
62 |
I found that the control's needle/knob is too small to touch, is it possible somehow to make it working
|
61 |
How can I rotate/move multiple layers once the user drags the layer
|
60 |
How can I show a layer as disabled
exgauge1.BeginUpdate(); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob 1"; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers.Add("original"); var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoMove; var_Layer.Background.Picture.Name = "Layer2.png"; var_Layer.DefaultOffsetY = -164; var_Layer.Grayscale = 0; exontrol.EXGAUGELib.Layer var_Layer1 = exgauge1.Layers.Add("grayscale 50%"); var_Layer1.Background.Picture.Name = "Layer2.png"; var_Layer1.Grayscale = 50; var_Layer1.DefaultOffsetY = -82; exontrol.EXGAUGELib.Layer var_Layer2 = exgauge1.Layers.Add("grayscale 100%"); var_Layer2.Background.Picture.Name = "Layer2.png"; var_Layer2.Grayscale = 100; exgauge1.EndUpdate(); |
59 |
Is it possible to stretch all layers
|
58 |
Tic Tac Toe Game
// MouseDown event - Occurs when the user presses a mouse button. private void exgauge1_MouseDownEvent(object sender,short Button,short Shift,int X,int Y) { // Left = Me.Layers(l).Left // Top = Me.Layers(l).Top // Width = Me.Layers(l).Width // Height = Me.Layers(l).Height int l = exgauge1.get_LayerFromPoint(-1,-1); exontrol.EXGAUGELib.Layers var_Layers = exgauge1.Layers; exontrol.EXGAUGELib.Layer var_Layer = var_Layers.Add(exgauge1.Layers.Count); exontrol.EXGAUGELib.Picture var_Picture = var_Layer.Background.Picture; var_Picture.Left = "8"; var_Picture.Width = "width - 2 * 8"; var_Picture.Top = "8"; var_Picture.Height = "height - 2 * 8"; var_Picture.Name = exgauge1.FormatABC("A mod 2 = 0 ? `x` : `o`",exgauge1.Layers.Count,null,null); var_Layer.Transparency = 0; } //this.exgauge1.MouseDownEvent += new exontrol.EXGAUGELib.exg2antt.MouseDownEventHandler(this.exgauge1_MouseDownEvent); exgauge1.BeginUpdate(); exgauge1.VisualAppearance.Add(1,"gBFLBCJwBAEHhEJAAEhABS0IQAAYAQGKIYBkAKBQAGaAoDDcMQ5QwAAyDGKEEwsACEIrjKCRShyCYZRhGcTALD8EhhECTZKkAZAEiWIovRbHMBzFIMYRFFCcIRGSaYD" + "iCNovTRNE7TfBMIhkGoSaKpCIRVDCSYJUzTc6wS79KgAASiJjjao6ZhaSpSABRYiyXRlHSxLiuYyoGTrJACEQxDhEEIjGLAazLMadJItCzabqGbJ8Ro6cQwTAIgI="); exgauge1.set_DefaultLayer(exontrol.EXGAUGELib.DefaultLayerPropertyEnum.exDefLayerWidth,"width/3"); exgauge1.set_DefaultLayer(exontrol.EXGAUGELib.DefaultLayerPropertyEnum.exDefLayerHeight,"height/3"); exgauge1.set_HTMLPicture("x","C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Pictures\\x.png"); exgauge1.set_HTMLPicture("o","C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Pictures\\o.png"); exgauge1.LayerAutoSize = -1; exgauge1.Layers.Count = 9; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[0]; var_Layer.Background.Color.Value32 = 0x1000000; exontrol.EXGAUGELib.Layer var_Layer1 = exgauge1.Layers[1]; var_Layer1.Left = " width/3 - 4"; var_Layer1.Background.Color.Value32 = 0x1000000; exontrol.EXGAUGELib.Layer var_Layer2 = exgauge1.Layers[2]; var_Layer2.Left = "2 * (width/3 - 4) - 4"; var_Layer2.Background.Color.Value32 = 0x1000000; exontrol.EXGAUGELib.Layer var_Layer3 = exgauge1.Layers[3]; var_Layer3.Top = "height/3 - 4"; var_Layer3.Background.Color.Value32 = 0x1000000; exontrol.EXGAUGELib.Layer var_Layer4 = exgauge1.Layers[4]; var_Layer4.Top = "height/3 - 4"; var_Layer4.Left = " width/3 - 4"; var_Layer4.Background.Color.Value32 = 0x1000000; exontrol.EXGAUGELib.Layer var_Layer5 = exgauge1.Layers[5]; var_Layer5.Top = "height/3 - 4"; var_Layer5.Left = "2 * (width/3 - 4) - 4"; var_Layer5.Background.Color.Value32 = 0x1000000; exontrol.EXGAUGELib.Layer var_Layer6 = exgauge1.Layers[6]; var_Layer6.Top = "2 * (height/3 - 4) "; var_Layer6.Background.Color.Value32 = 0x1000000; exontrol.EXGAUGELib.Layer var_Layer7 = exgauge1.Layers[7]; var_Layer7.Top = "2 * (height/3 - 4) "; var_Layer7.Left = " width/3 - 4"; var_Layer7.Background.Color.Value32 = 0x1000000; exontrol.EXGAUGELib.Layer var_Layer8 = exgauge1.Layers[8]; var_Layer8.Top = "2 * (height/3 - 4) "; var_Layer8.Left = "2 * (width/3 - 4) - 4"; var_Layer8.Background.Color.Value32 = 0x1000000; exgauge1.set_DefaultLayer(exontrol.EXGAUGELib.DefaultLayerPropertyEnum.exDefLayerTransparency,99); exgauge1.EndUpdate(); |
57 |
What's the difference Rotate vs Rotamove
// DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { // DragInfo.Debug = 227 } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); exgauge1.AllowSmoothChange = exontrol.EXGAUGELib.SmoothPropertyEnum.exSmoothChangeless; exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Linear\\Button with LEDs"; exontrol.EXGAUGELib.Layers var_Layers = exgauge1.Layers; exontrol.EXGAUGELib.Layer var_Layer = var_Layers.Add("base"); exontrol.EXGAUGELib.Layer var_Layer1 = var_Layers.Add("rotate"); var_Layer1.ToolTip = var_Layer1.Key.ToString(); exontrol.EXGAUGELib.Picture var_Picture = var_Layer1.Background.Picture; var_Picture.Name = "Example Button Up.png"; var_Picture.Left = "width/2"; var_Picture.Top = "height/2"; var_Picture.Width = 128.ToString(); var_Picture.Height = 64.ToString(); exontrol.EXGAUGELib.Foreground var_Foreground = var_Layer1.Foreground; var_Foreground.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,"<font ;14><sha ;;0>Rotate"); var_Foreground.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionLeft,"width/2 + 32"); var_Foreground.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,"height/2 + 16"); var_Layer1.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exRedChannel,100); var_Layer1.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; var_Layer1.RotateAngle = 45; exontrol.EXGAUGELib.Layer var_Layer2 = var_Layers.Add("rotamove"); var_Layer2.ToolTip = var_Layer2.Key.ToString(); exontrol.EXGAUGELib.Picture var_Picture1 = var_Layer2.Background.Picture; var_Picture1.Name = "Example Button Up.png"; var_Picture1.Left = "width/2"; var_Picture1.Top = "height/2"; var_Picture1.Width = 128.ToString(); var_Picture1.Height = 64.ToString(); exontrol.EXGAUGELib.Foreground var_Foreground1 = var_Layer2.Foreground; var_Foreground1.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,"<font ;14><sha ;;0>Rotamove"); var_Foreground1.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionLeft,"width/2 + 24"); var_Foreground1.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,"height/2 + 16"); var_Layer2.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exGreenChannel,100); var_Layer2.RotateAngle = 45; var_Layer2.Transparency = 25; var_Layer2.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotamove; |
56 |
How do I display a tooltip, when cursor hovers the layer
|
55 |
I've noticed that the OnDrag can move the layer itself, but how about moving the clipping region
|
54 |
How do I show a portion of layer with a different color (sample 2)
// Change event - Occurs when the layer's value is changed. private void exgauge1_Change(object sender,int Layer) { exgauge1.Layers["Color"].Clip.Value = exgauge1.Layers["Thumb"].RotateAngle; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers["Color"]; var_Layer.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exBlueChannel,var_Layer.RotateAngle); exgauge1.Layers["Thumb"].set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exBlueChannel,exgauge1.Layers["Color"].RotateAngle); } //this.exgauge1.Change += new exontrol.EXGAUGELib.exg2antt.ChangeEventHandler(this.exgauge1_Change); exgauge1.BeginUpdate(); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob 1"; exgauge1.PicturesName = "`Layer` + int(value + 1) + `.png`"; exgauge1.Layers.Count = 5; exgauge1.Layers[1].Visible = false; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[4]; var_Layer.Key = "Thumb"; var_Layer.DefaultRotateAngle = -141; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; var_Layer.RotateType = exontrol.EXGAUGELib.RotateTypeEnum.exRotateBilinearInterpolation; var_Layer.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exAllChannels,0); var_Layer.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exRedChannel,100); exontrol.EXGAUGELib.Layer var_Layer1 = exgauge1.Layers.Add("Color"); var_Layer1.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; var_Layer1.Position = 3; var_Layer1.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exAllChannels,0); var_Layer1.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exRedChannel,100); var_Layer1.Background.Picture.Name = "Layer3.png"; var_Layer1.Clip.Pie.SweepAngle = "value"; exontrol.EXGAUGELib.ClipEllipse var_ClipEllipse = var_Layer1.Clip.Ellipse; var_ClipEllipse.RadiusX = "150"; var_ClipEllipse.RadiusY = "150"; var_ClipEllipse.InverseClip = true; exgauge1.Layers["Thumb"].RotateAngle = 135; exgauge1.EndUpdate(); |
53 |
How do I show a portion of layer with a different color (sample 1)
// Change event - Occurs when the layer's value is changed. private void exgauge1_Change(object sender,int Layer) { exgauge1.Layers["Color"].Clip.Value = exgauge1.Layers["Thumb"].RotateAngle; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers["Color"]; var_Layer.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exBlueChannel,var_Layer.RotateAngle); exgauge1.Layers["Thumb"].set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exBlueChannel,exgauge1.Layers["Color"].RotateAngle); } //this.exgauge1.Change += new exontrol.EXGAUGELib.exg2antt.ChangeEventHandler(this.exgauge1_Change); exgauge1.BeginUpdate(); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob 1"; exgauge1.PicturesName = "`Layer` + int(value + 1) + `.png`"; exgauge1.Layers.Count = 5; exgauge1.Layers[1].Visible = false; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[4]; var_Layer.Key = "Thumb"; var_Layer.DefaultRotateAngle = -141; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; var_Layer.RotateType = exontrol.EXGAUGELib.RotateTypeEnum.exRotateBilinearInterpolation; var_Layer.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exAllChannels,0); var_Layer.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exGreenChannel,100); exontrol.EXGAUGELib.Layer var_Layer1 = exgauge1.Layers.Add("Color"); var_Layer1.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; var_Layer1.Position = 3; var_Layer1.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exAllChannels,0); var_Layer1.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exGreenChannel,100); var_Layer1.Background.Picture.Name = "Layer3.png"; var_Layer1.Clip.Pie.SweepAngle = "value"; exgauge1.Layers["Thumb"].RotateAngle = 135; exgauge1.EndUpdate(); |
52 |
How can I display / clip a picture with no transparency
exgauge1.BeginUpdate(); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob 1"; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers.Add("default"); var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoMove; var_Layer.Background.Picture.Name = "Layer2.png"; var_Layer.DefaultOffsetY = -164; exontrol.EXGAUGELib.Layer var_Layer1 = exgauge1.Layers.Add("notransparency"); var_Layer1.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoMove; var_Layer1.Background.Picture.Name = "Layer2.png"; exontrol.EXGAUGELib.ClipPicture var_ClipPicture = var_Layer1.Clip.Picture; var_ClipPicture.Name = exgauge1.Layers["notransparency"].Background.Picture.Name; var_ClipPicture.AlphaTo = "128"; var_Layer1.Grayscale = 100; exgauge1.EndUpdate(); |
51 |
How can I resize all layers
exgauge1.BeginUpdate(); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob 2"; exgauge1.PicturesName = "`Layer` + int(value + 1) + `.png`"; exgauge1.Layers.Count = 5; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers.Add("autosize"); var_Layer.Visible = false; var_Layer.Width = 164.ToString(); var_Layer.Height = 128.ToString(); exgauge1.LayerAutoSize = exgauge1.Layers["autosize"].Index; exgauge1.EndUpdate(); |
50 |
How can I start moving any layer when user clicks it
// DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { // Layers(DragInfo.Layer).OnDrag = 1 } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob"; exgauge1.PicturesName = "`Layer` + int(value + 1) + `.png`"; exgauge1.Layers.Count = 11; |
49 |
How can I prevent dragging the layers when user right click it
// DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { // Cancel = Me.FormatABC("A=2",DragInfo.Button) } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob"; exgauge1.PicturesName = "`Layer` + int(value + 1) + `.png`"; exgauge1.Layers.Count = 11; exgauge1.Layers[0].OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoMove; |
48 |
Is your control DPI-Aware
exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob"; exgauge1.PicturesName = "`Layer` + str(value + 1) + `.png`"; exgauge1.set_DefaultLayer(exontrol.EXGAUGELib.DefaultLayerPropertyEnum.exDefLayerRotateType,2); exgauge1.Layers.Count = 11; exgauge1.Layers[3].Grayscale = 100; exgauge1.Layers[4].Grayscale = 100; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[10]; var_Layer.Width = "128 * dpix"; var_Layer.Height = "128 * dpiy"; exgauge1.Layers[9].OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; exgauge1.LayerAutoSize = 10; |
47 |
Is it possible to make the control transparent, I would like to put the control on a form, then make the form transparent so the control appears on the desktop with just the images contained in the layers visible
|
46 |
How can I show the layers on perspective
|
45 |
Is it possible to resize all layers after they are loaded (method 2)
exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob"; exgauge1.PicturesName = "`Layer` + str(value + 1) + `.png`"; exgauge1.set_DefaultLayer(exontrol.EXGAUGELib.DefaultLayerPropertyEnum.exDefLayerRotateType,2); exgauge1.Layers.Count = 11; exgauge1.Layers[3].Grayscale = 100; exgauge1.Layers[4].Grayscale = 100; exgauge1.Layers[9].OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[10]; var_Layer.Width = 128.ToString(); var_Layer.Height = 128.ToString(); exgauge1.LayerAutoSize = 10; |
44 |
Is it possible to resize all layers after they are loaded (method 1)
|
43 |
Is it possible to load images for different layers from different folders
exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob"; exgauge1.PicturesName = "`Layer` + str(value + 1) + `.png`"; exgauge1.Layers.Count = 12; exgauge1.Layers[0].Background.Picture.Name = "\\..\\Clock\\vista_clock.png"; exgauge1.Layers[9].Background.Picture.Name = "\\..\\Knob 2\\Layer3.png"; exgauge1.Layers[10].Background.Picture.Name = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Led\\Speed\\noBack.png"; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[11]; var_Layer.DefaultOffsetX = 64; var_Layer.DefaultOffsetY = -36; exontrol.EXGAUGELib.Picture var_Picture = var_Layer.Background.Picture; var_Picture.Name = "gCJKBOI4NBQaBQAhQNJJIIhShQAEEREAIA0ROZ6PT0hQEX5JIhBKhYQrFSxNNhUKoUY7/c6+R6+a7pPg0UAjaISTQwCzMEgtWQ2IyDBJJMYiNJCJgTVJuMghNTcSgFA" + "xlNZiMinYKNRQ2NxMBhWNQkSRUAQkRRNEhYEBhMogMADOwGfY6N7eXb3DgXeamZgMGbQIStE55RZ7c7ce7/XpzZycOaBf7ZNAlZwiGQIMAnQBnAL4ACKAACABXADMAY4" + "BLgHYiXS6VQAESyDbAHYAGwvea9E4BXhPIgXD4KQCZD4FeAJzqWFLcNQf1KkSgyFYGMDmVoAEwAHjxQDiOo7AbgKqlaj8WQBRgxDYBfmabpDRTXdumF5ZSwVboXIBrTo" + "AhgBIwHWFREvoNZtlsb42G6Kg2g4b59AeYgAnAMpWnqBZWk2JoIkQcY8AGQAvgAPBWkcScUnceh6FoLYWAsepsGwLBsCcMIMh8C4AHYOAODOVIUHaYwviKMgvh2eIxmO" + "RxcnHJ5MjYExBlmM5nBAVgqGodY9nuFxXGoA5al8WIJmAe5OgAIxtD6bJUimU5uC4GxFiOaxXkOc59lwOh0kkFYREWFZ6iSdhiiMQBSg0VArFWAZ0CgepijEKJdlcBZn" + "nuaJ2n2PBZCgaAHnESZsHmRpFlKBBECQY5hA2DoOgaYYYCoC4zjObpAkCAJ+mVGgQBEFZ7CSVgbgYYYGk8c4ugODRFFgKRUnYAZ4C8E5ECqWwOl8d5/gcGgjmALQRjiU" + "BQmg9oVDWBAIFoAZ8DmBoAlcWoBlwWAjHEK5pnSehpDALR9A2U1+FWAB3B2X4rmCJwaBcLQNmiG4AG8do6FkLRWjEOw7GsEwRBQUogCIEBRH0LJEAQeR8h4c55jyXwDm" + "AK9TlMLIoBcS4pgAZwBGwaB3FIGIDBHopsmWS4Xh2HpUgoPhvkOcYcWANBWiCIh5GicJhnKUOvCcJp0CIGxNg6doEIUUopHSGoAA+OhhFeKgVBoGIYnCfo7HcTgdhuG4" + "zkWBB68GdJmkKQQPcSVx6Hue47l0foMAAZ5yjkXJTBoW5ekgSglFKZ4AAYO5BDwIAdkgZZykcWg3G8OoPlgNpDicT4fH6AwZk+M4zDEMwZGMVB9GGZgqGeO51kmfAbny" + "GQZjSVofmeepzB8Nojmqah+gQEAzCsKfvgoI5oniYOvCCZaghiWfeiWNY2mOOJ2CMKJyDUVpOhwR38EcDpWlq/4Ox6xLAxCMIkRAShQCoC4C4D42RaCpH+BAGY1wDiDF" + "oGgbwFQIjbHuH0Y48x+BUCeE8O47h0DRBeN8FwFAFC7ESMgJ4AAOARFyCsOQSgIhbEsK0FoywZC2DaOsFAig3DOGYMwPguAzjPE8G8QZFT1ghEA5IG4QhaHIB4M8Jrag" + "UitDqK5jIrhvj2HoLYU49hHjvA+NsWQZRligHWLoDwRAkAaGcBICIExIshBwAgQQ8ojjMCeAcB4Hh8DiGMI0X4rhiixEyNcLQBwRASAEIgKAKxjB7CMEAfIfhbjrB0E4" + "JQGxOgWEiF4CIzhFjgDi+gfQdh2jaBqLQPo+x7CNHSEwYwfwWCfHeA5WYXgsBYAQG4bougag/B6P0eYHwpg/A4D8F4pBXArGQJwRI9RviGHyDYQARQAAVAAPoTwAACCQ" + "GoCADgrxljzF0KwVwbgDBnGIJIDgGxnCxHgDoGInAxhmC+O4agjwUCQBMEIVAiA3ALCiMkRAKgAhcGsHEKgTg3BFikGoEQ3hqCkE0DsMILQbgCGADgVwGwsiOCKCYGQB" + "BAgREiKoRABIkATGYK4AAThJAGBCEACYEAEhRGKBAFoCAmBgEYAkSQCQthtEuPsWwAAkgUCIAARzUgnD3HoHAS46xMDFWgDUbQLAlDMgiKsFwIw2AzGwEoUQJXQjXCIG" + "IAwQhUh9DiJQBAxwQAwFID0IA2wjCkCQBEBYUw3g2AWMsKwNAvgqFWLQJIOwbAcBOEIMgLwxDRGkNACw7gAAwDUPkRokwYBrCKKQLo1xKhIDWGEMYOhnCGD+AETIaBOC" + "ABEEYVY0yI1SCKE4IgrghBgEEQEA="; var_Picture.Width = 64.ToString(); var_Picture.Height = 64.ToString(); |
42 |
How can I specify whether an object can be selected or not
// MouseMove event - Occurs when the user moves the mouse. private void exgauge1_MouseMoveEvent(object sender,short Button,short Shift,int X,int Y) { System.Diagnostics.Debug.Print( exgauge1.get_LayerFromPoint(-1,-1).ToString() ); } //this.exgauge1.MouseMoveEvent += new exontrol.EXGAUGELib.exg2antt.MouseMoveEventHandler(this.exgauge1_MouseMoveEvent); exgauge1.BeginUpdate(); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob"; exgauge1.PicturesName = "`Layer` + str(value + 1) + `.png`"; exgauge1.Layers.Count = 12; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[10]; var_Layer.RotateType = exontrol.EXGAUGELib.RotateTypeEnum.exRotateBilinearInterpolation; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; exontrol.EXGAUGELib.Picture var_Picture = var_Layer.Background.get_ExtraPicture("extra1"); var_Picture.Name = "Layer1.png"; var_Picture.Left = "32"; var_Picture.Top = "32"; var_Picture.Width = 64.ToString(); var_Picture.Height = 64.ToString(); exontrol.EXGAUGELib.Foreground var_Foreground = var_Layer.Foreground; var_Foreground.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,"<sha ;;0>selectable"); var_Foreground.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionLeft,38); var_Foreground.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,-5); exontrol.EXGAUGELib.Layer var_Layer1 = exgauge1.Layers[11]; exontrol.EXGAUGELib.Picture var_Picture1 = var_Layer1.Background.get_ExtraPicture("extra2"); var_Picture1.Name = "Layer1.png"; var_Picture1.Left = "width-64"; var_Picture1.Top = "height-84 - 32"; var_Picture1.Width = 64.ToString(); var_Picture1.Height = 64.ToString(); var_Picture1.Selectable = false; var_Layer1.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exAllChannels,25); exontrol.EXGAUGELib.Foreground var_Foreground1 = var_Layer1.Foreground; var_Foreground1.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,"<sha ;;0>not selectable"); var_Foreground1.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionAnchor,8); var_Foreground1.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,"height-theight/4"); exgauge1.EndUpdate(); |
41 |
How do I get the layer/object/picture from the cursor
// MouseMove event - Occurs when the user moves the mouse. private void exgauge1_MouseMoveEvent(object sender,short Button,short Shift,int X,int Y) { System.Diagnostics.Debug.Print( exgauge1.get_LayerFromPoint(-1,-1).ToString() ); } //this.exgauge1.MouseMoveEvent += new exontrol.EXGAUGELib.exg2antt.MouseMoveEventHandler(this.exgauge1_MouseMoveEvent); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob"; exgauge1.PicturesName = "`Layer` + str(value + 1) + `.png`"; exgauge1.Layers.Count = 10; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[9]; var_Layer.RotateType = exontrol.EXGAUGELib.RotateTypeEnum.exRotateBilinearInterpolation; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; |
40 |
How can I display a speedometer
// Change event - Occurs when the layer's value is changed. private void exgauge1_Change(object sender,int Layer) { exgauge1.Layers["arc"].Clip.Value = exgauge1.Value; exgauge1.Layers["noDigit"].Background.get_ExtraPicture("80").Name = exgauge1.FormatABC("`no` + int((value MIN 0 MAX 99)/10) + `.png`",exgauge1.Value,null,null); exgauge1.Layers["noDigit"].Background.get_ExtraPicture("08").Name = exgauge1.FormatABC("`no` + int((value MIN 0 MAX 99) mod 10) + `.png`",exgauge1.Value,null,null); } //this.exgauge1.Change += new exontrol.EXGAUGELib.exg2antt.ChangeEventHandler(this.exgauge1_Change); // MouseWheel event - Occurs when the mouse wheel moves while the control has focus private void exgauge1_MouseWheel(object sender,int Delta) { exgauge1.Value = exgauge1.FormatABC("value + B",exgauge1.Value,Delta,null); } //this.exgauge1.MouseWheel += new exontrol.EXGAUGELib.exg2antt.MouseWheelEventHandler(this.exgauge1_MouseWheel); exgauge1.BeginUpdate(); exgauge1.BackColor = Color.FromArgb(40,40,40); exgauge1.AllowSmoothChange = exontrol.EXGAUGELib.SmoothPropertyEnum.exSmoothChangeless; exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Led\\Speed"; exgauge1.Layers.Count = 6; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[0]; var_Layer.Key = "arcBack"; var_Layer.Background.Picture.Name = "noArcBack.png"; exontrol.EXGAUGELib.ClipPie var_ClipPie = var_Layer.Clip.Pie; var_ClipPie.StartAngle = 240.ToString(); var_ClipPie.SweepAngle = 240.ToString(); exontrol.EXGAUGELib.Layer var_Layer1 = exgauge1.Layers[1]; var_Layer1.Key = "arc"; var_Layer1.Background.Picture.Name = "noArc.png"; exontrol.EXGAUGELib.ClipPie var_ClipPie1 = var_Layer1.Clip.Pie; var_ClipPie1.StartAngle = 240.ToString(); var_ClipPie1.SweepAngle = "value/100 * 240"; exontrol.EXGAUGELib.Layer var_Layer2 = exgauge1.Layers[2]; var_Layer2.RotateType = exontrol.EXGAUGELib.RotateTypeEnum.exRotateBilinearInterpolation; var_Layer2.Key = "pointer"; var_Layer2.Background.Picture.Name = "noLine.png"; var_Layer2.DefaultRotateAngle = 240; var_Layer2.RotateAngleToValue = "value/240 * 100"; var_Layer2.ValueToRotateAngle = "value / 100 * 240"; var_Layer2.RotateAngleValid = "value > 240 ? (value > 300 ? 0 : 240) : value"; var_Layer2.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; exontrol.EXGAUGELib.Layer var_Layer3 = exgauge1.Layers[3]; var_Layer3.Key = "noBack"; var_Layer3.Left = "(width - 55 * 2)/2"; var_Layer3.Top = "(height - 94 * 1)/2"; var_Layer3.Width = "2 * 45 + 8"; var_Layer3.Height = "1 * 94"; var_Layer3.Transparency = 90; exontrol.EXGAUGELib.Picture var_Picture = var_Layer3.Background.get_ExtraPicture("80"); var_Picture.Name = "noBack.png"; var_Picture.Left = "-4"; var_Picture.Width = "70"; exontrol.EXGAUGELib.Picture var_Picture1 = var_Layer3.Background.get_ExtraPicture("08"); var_Picture1.Name = "noBack.png"; var_Picture1.Left = "36"; var_Picture1.Width = 70.ToString(); exontrol.EXGAUGELib.Layer var_Layer4 = exgauge1.Layers[4]; var_Layer4.Key = "noDigit"; var_Layer4.Left = "(width - 55 * 2)/2"; var_Layer4.Top = "(height - 94 * 1)/2"; var_Layer4.Width = "2 * 45 + 8"; var_Layer4.Height = "1 * 94"; exontrol.EXGAUGELib.Picture var_Picture2 = var_Layer4.Background.get_ExtraPicture("80"); var_Picture2.Name = "no1.png"; var_Picture2.Left = "-4"; var_Picture2.Width = "70"; exontrol.EXGAUGELib.Picture var_Picture3 = var_Layer4.Background.get_ExtraPicture("08"); var_Picture3.Name = "no2.png"; var_Picture3.Left = "36"; var_Picture3.Width = 70.ToString(); exontrol.EXGAUGELib.Layer var_Layer5 = exgauge1.Layers[5]; var_Layer5.Key = "noCap"; var_Layer5.Background.Picture.Name = "noCap.png"; var_Layer5.Transparency = 45; exgauge1.Layers["pointer"].Position = exgauge1.Layers["noCap"].Position; exgauge1.LayerOfValue = exgauge1.Layers["pointer"].Index; exgauge1.Value = 56; exgauge1.EndUpdate(); |
39 |
How can I display LED-numbers
// Change event - Occurs when the layer's value is changed. private void exgauge1_Change(object sender,int Layer) { exgauge1.Value = exgauge1.FormatABC("value MIN 0 MAX 99",.Value,null,null); exgauge1.Layers["noDigit"].Background.get_ExtraPicture("80").Name = exgauge1.FormatABC("`no` + int((value MIN 0 MAX 99)/10) + `.png`",exgauge1.Value,null,null); exgauge1.Layers["noDigit"].Background.get_ExtraPicture("08").Name = exgauge1.FormatABC("`no` + int((value MIN 0 MAX 99) mod 10) + `.png`",exgauge1.Value,null,null); } //this.exgauge1.Change += new exontrol.EXGAUGELib.exg2antt.ChangeEventHandler(this.exgauge1_Change); // MouseWheel event - Occurs when the mouse wheel moves while the control has focus private void exgauge1_MouseWheel(object sender,int Delta) { exgauge1.Value = exgauge1.FormatABC("value + B",exgauge1.Layers["noDigit"].Value,Delta,null); } //this.exgauge1.MouseWheel += new exontrol.EXGAUGELib.exg2antt.MouseWheelEventHandler(this.exgauge1_MouseWheel); // Timer event - Occurs when the interval elapses. private void exgauge1_Timer(object sender,int TickCount) { exgauge1.Value = exgauge1.FormatABC("value = 99 ? 0 : ( value + B )",exgauge1.Value,1,null); } //this.exgauge1.Timer += new exontrol.EXGAUGELib.exg2antt.TimerEventHandler(this.exgauge1_Timer); exgauge1.BeginUpdate(); exgauge1.AllowSmoothChange = exontrol.EXGAUGELib.SmoothPropertyEnum.exSmoothChangeless; exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Led\\Speed"; exgauge1.Layers.Count = 3; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[1]; var_Layer.Key = "noBack"; var_Layer.Left = "(width - 55 * 2)/2"; var_Layer.Top = "(height - 94 * 1)/2"; var_Layer.Width = "2 * 45 + 8"; var_Layer.Height = "1 * 94"; var_Layer.Transparency = 90; exontrol.EXGAUGELib.Picture var_Picture = var_Layer.Background.get_ExtraPicture("80"); var_Picture.Name = "noBack.png"; var_Picture.Left = "-4"; var_Picture.Width = "70"; exontrol.EXGAUGELib.Picture var_Picture1 = var_Layer.Background.get_ExtraPicture("08"); var_Picture1.Name = "noBack.png"; var_Picture1.Left = "36"; var_Picture1.Width = 70.ToString(); exontrol.EXGAUGELib.Layer var_Layer1 = exgauge1.Layers[2]; var_Layer1.Key = "noDigit"; var_Layer1.Left = "(width - 55 * 2)/2"; var_Layer1.Top = "(height - 94 * 1)/2"; var_Layer1.Width = "2 * 45 + 8"; var_Layer1.Height = "1 * 94"; exontrol.EXGAUGELib.Picture var_Picture2 = var_Layer1.Background.get_ExtraPicture("80"); var_Picture2.Name = "no1.png"; var_Picture2.Left = "-4"; var_Picture2.Width = "70"; exontrol.EXGAUGELib.Picture var_Picture3 = var_Layer1.Background.get_ExtraPicture("08"); var_Picture3.Name = "no2.png"; var_Picture3.Left = "36"; var_Picture3.Width = 70.ToString(); exgauge1.LayerOfValue = exgauge1.Layers["noDigit"].Index; exgauge1.Value = 73; exgauge1.TimerInterval = 100; exgauge1.EndUpdate(); |
38 |
How can I display a simple knob, to fit the control's client area
exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob 1"; exgauge1.PicturesName = "`Layer` + str(value + 1) + `.png`"; exgauge1.LayerAutoSize = -1; exgauge1.set_DefaultLayer(exontrol.EXGAUGELib.DefaultLayerPropertyEnum.exDefLayerWidth,"width MAX height"); exgauge1.set_DefaultLayer(exontrol.EXGAUGELib.DefaultLayerPropertyEnum.exDefLayerHeight,"width MAX height"); exgauge1.Layers.Count = 5; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[4]; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotamove; var_Layer.DefaultRotateAngle = -142; |
37 |
How can I display a switch
// Click event - Occurs when the user presses and then releases the left mouse button over the control. private void exgauge1_Click(object sender) { exgauge1.Value = exgauge1.FormatABC("(value + 1) mod 2",.Value,null,null); } //this.exgauge1.Click += new exontrol.EXGAUGELib.exg2antt.ClickEventHandler(this.exgauge1_Click); // DragEnd event - Occurs once the user ends dragging a layer. private void exgauge1_DragEnd(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,bool Cancel) { exgauge1.Value = exgauge1.FormatABC("(value < 24 ? 0 : 1)",exgauge1.Layers["knob"].OffsetX,null,null); } //this.exgauge1.DragEnd += new exontrol.EXGAUGELib.exg2antt.DragEndEventHandler(this.exgauge1_DragEnd); // DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); // MouseWheel event - Occurs when the mouse wheel moves while the control has focus private void exgauge1_MouseWheel(object sender,int Delta) { exgauge1.Value = exgauge1.FormatABC("value > 0 ? 1 : 0",Delta,null,null); } //this.exgauge1.MouseWheel += new exontrol.EXGAUGELib.exg2antt.MouseWheelEventHandler(this.exgauge1_MouseWheel); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Linear\\Switch"; exgauge1.Layers.Count = 4; exgauge1.Layers[0].Background.Picture.Name = "background.png"; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[1]; exontrol.EXGAUGELib.Picture var_Picture = var_Layer.Background.Picture; var_Picture.Name = "Indicator_ON.png"; var_Picture.DisplayAs = exontrol.EXGAUGELib.PictureDisplayEnum.MiddleLeft; var_Layer.OffsetXValid = 48.ToString(); var_Layer.OffsetYValid = 0.ToString(); exontrol.EXGAUGELib.Layer var_Layer1 = exgauge1.Layers[2]; exontrol.EXGAUGELib.Picture var_Picture1 = var_Layer1.Background.Picture; var_Picture1.Name = "Indicator_OFF.png"; var_Picture1.DisplayAs = exontrol.EXGAUGELib.PictureDisplayEnum.MiddleRight; var_Layer1.OffsetXValid = -12.ToString(); var_Layer1.OffsetYValid = 0.ToString(); exontrol.EXGAUGELib.Layer var_Layer2 = exgauge1.Layers[3]; var_Layer2.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoMove; var_Layer2.Key = "knob"; exontrol.EXGAUGELib.Picture var_Picture2 = var_Layer2.Background.Picture; var_Picture2.Name = "knob.png"; var_Picture2.DisplayAs = exontrol.EXGAUGELib.PictureDisplayEnum.MiddleCenter; var_Layer2.DefaultOffsetY = "9"; var_Layer2.DefaultOffsetX = "-5"; var_Layer2.OffsetYValid = "0"; var_Layer2.ValueToOffsetX = "value = 0 ? 0 : 48"; var_Layer2.OffsetToValue = "value = 0 ? 0 : 1"; var_Layer2.OffsetXValid = "(value MIN 0 MAX 48)"; exgauge1.LayerOfValue = exgauge1.Layers["knob"].Index; exgauge1.Value = 1; |
36 |
How can I colorize the layer
// Change event - Occurs when the layer's value is changed. private void exgauge1_Change(object sender,int Layer) { exgauge1.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` Value: <b>` + (value format ``)",exgauge1.Layers[4].Value,null,null)); } //this.exgauge1.Change += new exontrol.EXGAUGELib.exg2antt.ChangeEventHandler(this.exgauge1_Change); // Click event - Occurs when the user presses and then releases the left mouse button over the control. private void exgauge1_Click(object sender) { Object var_Object = exgauge1.Layers[exgauge1.get_LayerFromPoint(-1,-1)]; } //this.exgauge1.Click += new exontrol.EXGAUGELib.exg2antt.ClickEventHandler(this.exgauge1_Click); // MouseIn event - Notifies that the cursor enters the layer. private void exgauge1_MouseIn(object sender,int Layer) { exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[Layer]; var_Layer.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exRedChannel,100); var_Layer.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exGreenChannel,0); var_Layer.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exBlueChannel,0); } //this.exgauge1.MouseIn += new exontrol.EXGAUGELib.exg2antt.MouseInEventHandler(this.exgauge1_MouseIn); // MouseOut event - Notifies that the cursor exits the layer. private void exgauge1_MouseOut(object sender,int Layer) { exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[Layer]; var_Layer.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exRedChannel,exgauge1.get_DefaultLayer(exontrol.EXGAUGELib.DefaultLayerPropertyEnum.exDefLayerBrightness)); var_Layer.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exGreenChannel,exgauge1.get_DefaultLayer(exontrol.EXGAUGELib.DefaultLayerPropertyEnum.exDefLayerBrightness)); var_Layer.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exBlueChannel,exgauge1.get_DefaultLayer(exontrol.EXGAUGELib.DefaultLayerPropertyEnum.exDefLayerBrightness)); } //this.exgauge1.MouseOut += new exontrol.EXGAUGELib.exg2antt.MouseOutEventHandler(this.exgauge1_MouseOut); // MouseWheel event - Occurs when the mouse wheel moves while the control has focus private void exgauge1_MouseWheel(object sender,int Delta) { exgauge1.Value = exgauge1.FormatABC("A - B",.Value,Delta,null); } //this.exgauge1.MouseWheel += new exontrol.EXGAUGELib.exg2antt.MouseWheelEventHandler(this.exgauge1_MouseWheel); exgauge1.BeginUpdate(); exgauge1.set_DefaultLayer(exontrol.EXGAUGELib.DefaultLayerPropertyEnum.exDefLayerBrightness,51); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob 2"; exgauge1.PicturesName = "`Layer` + str(value + 1) + `.png`"; exgauge1.Layers.Count = 6; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[0]; var_Layer.RotateCenterX = "lwidth/2-3"; var_Layer.RotateCenterY = "lheight/2+23"; exontrol.EXGAUGELib.Layer var_Layer1 = exgauge1.Layers[4]; var_Layer1.DefaultRotateAngle = -132; var_Layer1.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotamove; var_Layer1.RotateAngleValid = "value < 0 ? 0 : (value > 236 ? (value > 300 ? 0 : 236 ) : value)"; var_Layer1.ValueToRotateAngle = "value < 20 ? (value /20 * 86) : (value - 20) / (90-20) * (236-86) + 86"; var_Layer1.RotateAngleToValue = "value < 86 ? value / 86 * 20: ( 20 + ( value -86 ) / (236-86) * 70 )"; exgauge1.Value = 45; exgauge1.EndUpdate(); |
35 |
How can I imitate the rotating angle on an unequal scale
// Change event - Occurs when the layer's value is changed. private void exgauge1_Change(object sender,int Layer) { exgauge1.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` Value: <b>` + (value format ``)",exgauge1.Layers[4].Value,null,null)); } //this.exgauge1.Change += new exontrol.EXGAUGELib.exg2antt.ChangeEventHandler(this.exgauge1_Change); // MouseWheel event - Occurs when the mouse wheel moves while the control has focus private void exgauge1_MouseWheel(object sender,int Delta) { exgauge1.Value = exgauge1.FormatABC("A - B",.Value,Delta,null); } //this.exgauge1.MouseWheel += new exontrol.EXGAUGELib.exg2antt.MouseWheelEventHandler(this.exgauge1_MouseWheel); exgauge1.BeginUpdate(); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob 2"; exgauge1.PicturesName = "`Layer` + str(value + 1) + `.png`"; exgauge1.Layers.Count = 6; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[0]; var_Layer.RotateCenterX = "lwidth/2-3"; var_Layer.RotateCenterY = "lheight/2+23"; exontrol.EXGAUGELib.Layer var_Layer1 = exgauge1.Layers[4]; var_Layer1.DefaultRotateAngle = -132; var_Layer1.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotamove; var_Layer1.RotateAngleValid = "value < 0 ? 0 : (value > 236 ? (value > 300 ? 0 : 236 ) : value)"; var_Layer1.ValueToRotateAngle = "value < 20 ? (value /20 * 86) : (value - 20) / (90-20) * (236-86) + 86"; var_Layer1.RotateAngleToValue = "value < 86 ? value / 86 * 20: ( 20 + ( value -86 ) / (236-86) * 70 )"; exgauge1.Value = 45; exgauge1.EndUpdate(); |
34 |
How can I rotate more knobs at once
// Change event - Occurs when the layer's value is changed. private void exgauge1_Change(object sender,int Layer) { exgauge1.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` Value: <b>` + (value format ``)",exgauge1.Layers[4].Value,null,null)); exgauge1.Layers[2].RotateAngle = exgauge1.Layers[4].RotateAngle; } //this.exgauge1.Change += new exontrol.EXGAUGELib.exg2antt.ChangeEventHandler(this.exgauge1_Change); // MouseWheel event - Occurs when the mouse wheel moves while the control has focus private void exgauge1_MouseWheel(object sender,int Delta) { exgauge1.Layers[4].RotateAngle = exgauge1.FormatABC("A - B",exgauge1.Layers[4].RotateAngle,Delta,null); } //this.exgauge1.MouseWheel += new exontrol.EXGAUGELib.exg2antt.MouseWheelEventHandler(this.exgauge1_MouseWheel); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob 1"; exgauge1.PicturesName = "`Layer` + str(value + 1) + `.png`"; exgauge1.Layers.Count = 5; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[4]; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotamove; var_Layer.DefaultRotateAngle = -142; exontrol.EXGAUGELib.Layer var_Layer1 = exgauge1.Layers[2]; var_Layer1.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; var_Layer1.RotateType = exontrol.EXGAUGELib.RotateTypeEnum.exRotateBilinearInterpolation; |
33 |
How can I clip one layer while other is rotating
// Change event - Occurs when the layer's value is changed. private void exgauge1_Change(object sender,int Layer) { exgauge1.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` Value: <b>` + (value format ``)",exgauge1.Layers[9].Value,null,null)); exgauge1.set_ExtraCaption("RotateAngle",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` RotateAngle: <b>` + ( A format `` ) + `°`",exgauge1.Layers[9].RotateAngle,null,null)); exgauge1.set_ExtraCaption("RotateAngle",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,18); exgauge1.set_ExtraCaption("RotamoveCenter",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` RotamoveCenter: <b> (` + A + `,` + B + `)`",exgauge1.Layers[9].RotamoveCenterX,exgauge1.Layers[9].RotamoveCenterY,null)); exgauge1.set_ExtraCaption("RotamoveCenter",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,36); exgauge1.set_ExtraCaption("RotamoveOffset",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` RotamoveOffset: <b> (` + A + `,` + B + `)`",exgauge1.Layers[9].RotamoveOffsetX,exgauge1.Layers[9].RotamoveOffsetY,null)); exgauge1.set_ExtraCaption("RotamoveOffset",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,54); exgauge1.set_ExtraCaption("Offset",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` Offset: <b> (` + A + `,` + B + `)`",exgauge1.Layers[9].OffsetX,exgauge1.Layers[9].OffsetY,null)); exgauge1.set_ExtraCaption("Offset",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,72); exgauge1.set_ExtraCaption("Client",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("`<sha ;;0><font ;12><b>` + ((100 - value) format ``)",exgauge1.Value,null,null)); exgauge1.set_ExtraCaption("Client",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionLeft,exgauge1.FormatABC("value - 12",[9].get_LayerToClientX(exgauge1.Layers.RotamoveCenterX,.RotamoveCenterY),null,null)); exgauge1.set_ExtraCaption("Client",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,exgauge1.FormatABC("value - 36",[9].get_LayerToClientY(exgauge1.Layers.RotamoveCenterX,.RotamoveCenterY),null,null)); exgauge1.Layers[3].Clip.Value = exgauge1.Layers[9].RotateAngle; exgauge1.Layers[4].Clip.Value = exgauge1.Layers[3].Clip.Value; } //this.exgauge1.Change += new exontrol.EXGAUGELib.exg2antt.ChangeEventHandler(this.exgauge1_Change); // DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { // DragInfo.RotateAngleValid = "value < 0 ? 0 : ( value >= 360 ? 359.999 : value )" } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); // MouseWheel event - Occurs when the mouse wheel moves while the control has focus private void exgauge1_MouseWheel(object sender,int Delta) { exgauge1.Value = exgauge1.FormatABC("100 - value - B",exgauge1.Value,Delta,null); } //this.exgauge1.MouseWheel += new exontrol.EXGAUGELib.exg2antt.MouseWheelEventHandler(this.exgauge1_MouseWheel); exgauge1.BeginUpdate(); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob"; exgauge1.PicturesName = "`Layer` + str(value + 1) + `.png`"; exgauge1.Layers.Count = 11; exgauge1.AllowSmoothChange = exontrol.EXGAUGELib.SmoothPropertyEnum.exSmoothChangeless; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[9]; var_Layer.DefaultRotateAngle = -126; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotamove; var_Layer.RotateAngleToValue = "100 - value / 360 * 100"; var_Layer.ValueToRotateAngle = "(value)/100 * 360"; exgauge1.Layers[3].Clip.Pie.SweepAngle = "value"; exgauge1.Layers[4].Clip.Pie.SweepAngle = exgauge1.Layers[3].Clip.Pie.SweepAngle; exgauge1.Layers[9].Value = 25; exgauge1.EndUpdate(); |
32 |
Can I move one or more layers at once
|
31 |
How can I rotate a knob by moving ( rotamove )
// Change event - Occurs when the layer's value is changed. private void exgauge1_Change(object sender,int Layer) { exgauge1.Layers[3].Transparency = exgauge1.Value; exgauge1.Layers[4].Transparency = exgauge1.Value; exgauge1.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` Value: <b>` + (100 - value format ``)",exgauge1.Layers[9].Value,null,null)); exgauge1.set_ExtraCaption("RotateAngle",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` RotateAngle: <b>` + ( A format `` ) + `°`",exgauge1.Layers[9].RotateAngle,null,null)); exgauge1.set_ExtraCaption("RotateAngle",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,18); exgauge1.set_ExtraCaption("RotamoveCenter",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` RotamoveCenter: <b> (` + A + `,` + B + `)`",exgauge1.Layers[9].RotamoveCenterX,exgauge1.Layers[9].RotamoveCenterY,null)); exgauge1.set_ExtraCaption("RotamoveCenter",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,36); exgauge1.set_ExtraCaption("RotamoveOffset",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` RotamoveOffset: <b> (` + A + `,` + B + `)`",exgauge1.Layers[9].RotamoveOffsetX,exgauge1.Layers[9].RotamoveOffsetY,null)); exgauge1.set_ExtraCaption("RotamoveOffset",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,54); exgauge1.set_ExtraCaption("Offset",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` Offset: <b> (` + A + `,` + B + `)`",exgauge1.Layers[9].OffsetX,exgauge1.Layers[9].OffsetY,null)); exgauge1.set_ExtraCaption("Offset",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,72); } //this.exgauge1.Change += new exontrol.EXGAUGELib.exg2antt.ChangeEventHandler(this.exgauge1_Change); // DblClick event - Occurs when the user dblclk the left mouse button over an object. private void exgauge1_DblClick(object sender,short Shift,int X,int Y) { exgauge1.Value = 0; } //this.exgauge1.DblClick += new exontrol.EXGAUGELib.exg2antt.DblClickEventHandler(this.exgauge1_DblClick); // DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { // DragInfo.RotateAngleValid = "value < 0 ? 0 : (value > 360 ? 359.999999 : value)" } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); // MouseWheel event - Occurs when the mouse wheel moves while the control has focus private void exgauge1_MouseWheel(object sender,int Delta) { exgauge1.Value = exgauge1.FormatABC("100 - A - B",exgauge1.Value,Delta,null); } //this.exgauge1.MouseWheel += new exontrol.EXGAUGELib.exg2antt.MouseWheelEventHandler(this.exgauge1_MouseWheel); exgauge1.BeginUpdate(); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob"; exgauge1.PicturesName = "`Layer` + str(value + 1) + `.png`"; exgauge1.Layers.Count = 11; exgauge1.AllowSmoothChange = exontrol.EXGAUGELib.SmoothPropertyEnum.exSmoothChangeless; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[9]; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotamove; var_Layer.DefaultRotateAngle = -126; var_Layer.RotateAngleToValue = "100 - value / 360 * 100"; var_Layer.ValueToRotateAngle = "(value)/100 * 360"; var_Layer.Background.get_ExtraPicture("Aka").Value = "Highlighted_Layer4.png"; exontrol.EXGAUGELib.Layer var_Layer1 = exgauge1.Layers[3]; var_Layer1.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exAllChannels,0); var_Layer1.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exRedChannel,100); exontrol.EXGAUGELib.Layer var_Layer2 = exgauge1.Layers[4]; var_Layer2.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotamove; var_Layer2.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exAllChannels,0); var_Layer2.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exRedChannel,100); exgauge1.Value = 15; exgauge1.EndUpdate(); |
30 |
How can I display a knob, and displays the current value on it
// Change event - Occurs when the layer's value is changed. private void exgauge1_Change(object sender,int Layer) { exgauge1.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` Value: <b>` + (100 - value format ``)",exgauge1.Layers[9].Value,null,null)); exgauge1.set_ExtraCaption("RotateAngle",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` RotateAngle: <b>` + ( A format `` ) + `°`",exgauge1.Layers[9].RotateAngle,null,null)); exgauge1.set_ExtraCaption("RotateAngle",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,18); exgauge1.set_ExtraCaption("RotamoveCenter",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` RotamoveCenter: <b> (` + A + `,` + B + `)`",exgauge1.Layers[9].RotamoveCenterX,exgauge1.Layers[9].RotamoveCenterY,null)); exgauge1.set_ExtraCaption("RotamoveCenter",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,36); exgauge1.set_ExtraCaption("RotamoveOffset",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` RotamoveOffset: <b> (` + A + `,` + B + `)`",exgauge1.Layers[9].RotamoveOffsetX,exgauge1.Layers[9].RotamoveOffsetY,null)); exgauge1.set_ExtraCaption("RotamoveOffset",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,54); exgauge1.set_ExtraCaption("Offset",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("` Offset: <b> (` + A + `,` + B + `)`",exgauge1.Layers[9].OffsetX,exgauge1.Layers[9].OffsetY,null)); exgauge1.set_ExtraCaption("Offset",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,72); exgauge1.set_ExtraCaption("Client",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("`<sha ;;0><font ;12><b>` + (100 - value format `0`)",exgauge1.Value,null,null)); exgauge1.set_ExtraCaption("Client",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionLeft,exgauge1.FormatABC("value - 8",exgauge1.Layers[9].get_LayerToClientX(exgauge1.Layers[9].RotamoveCenterX,exgauge1.Layers[9].RotamoveCenterY),null,null)); exgauge1.set_ExtraCaption("Client",exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaptionTop,exgauge1.FormatABC("value - 26",exgauge1.Layers[9].get_LayerToClientY(exgauge1.Layers[9].RotamoveCenterX,exgauge1.Layers[9].RotamoveCenterY),null,null)); exgauge1.Layers[7].RotateAngle = exgauge1.Layers[0].RotateAngle; } //this.exgauge1.Change += new exontrol.EXGAUGELib.exg2antt.ChangeEventHandler(this.exgauge1_Change); // MouseWheel event - Occurs when the mouse wheel moves while the control has focus private void exgauge1_MouseWheel(object sender,int Delta) { exgauge1.Value = exgauge1.FormatABC("100 - A - B",exgauge1.Value,Delta,null); } //this.exgauge1.MouseWheel += new exontrol.EXGAUGELib.exg2antt.MouseWheelEventHandler(this.exgauge1_MouseWheel); exgauge1.BeginUpdate(); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob"; exgauge1.PicturesName = "`Layer` + str(value + 1) + `.png`"; exgauge1.Layers.Count = 11; exgauge1.AllowSmoothChange = exontrol.EXGAUGELib.SmoothPropertyEnum.exSmoothChangeless; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[9]; var_Layer.DefaultRotateAngle = -126; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotamove; var_Layer.RotateAngleToValue = "100 - (value / 360 * 100)"; var_Layer.ValueToRotateAngle = "(value)/100 * 360"; var_Layer.ValueToOffsetX = "value"; var_Layer.OffsetToValue = "value"; var_Layer.RotateAngleValid = "int(value / 360 * 100)/100 * 360"; exgauge1.Layers[3].Visible = false; exgauge1.Layers[4].Visible = false; exontrol.EXGAUGELib.Layer var_Layer1 = exgauge1.Layers[0]; var_Layer1.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; var_Layer1.RotateType = exontrol.EXGAUGELib.RotateTypeEnum.exRotateBilinearInterpolation; exontrol.EXGAUGELib.Layer var_Layer2 = exgauge1.Layers[7]; var_Layer2.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; var_Layer2.RotateType = exontrol.EXGAUGELib.RotateTypeEnum.exRotateBilinearInterpolation; exgauge1.Value = 25; exgauge1.EndUpdate(); |
29 |
How can I display an indicator
// MouseWheel event - Occurs when the mouse wheel moves while the control has focus private void exgauge1_MouseWheel(object sender,int Delta) { exgauge1.Layers[1].Clip.Value = exgauge1.FormatABC("(value + B) MIN 0 MAX 100",.Layers[1].Clip.Value,Delta,null); } //this.exgauge1.MouseWheel += new exontrol.EXGAUGELib.exg2antt.MouseWheelEventHandler(this.exgauge1_MouseWheel); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Linear\\Indicator"; exgauge1.Layers.Count = 3; exgauge1.Layers[0].Background.Picture.Name = "Background.png"; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[1]; var_Layer.Background.Picture.Name = "Green_Lights.png"; exontrol.EXGAUGELib.Clip var_Clip = var_Layer.Clip; exontrol.EXGAUGELib.ClipRectangle var_ClipRectangle = var_Clip.Rectangle; var_ClipRectangle.Height = "(100 - value)/100 * height"; var_ClipRectangle.InverseClip = true; var_Clip.Value = 50; exontrol.EXGAUGELib.Layer var_Layer1 = exgauge1.Layers[2]; var_Layer1.Visible = false; var_Layer1.Background.Picture.Name = "overlay_top_layer.png"; |
28 |
How can I display a gauge
// Change event - Occurs when the layer's value is changed. private void exgauge1_Change(object sender,int Layer) { exgauge1.Layers[1].set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exGreenChannel,exgauge1.Value); } //this.exgauge1.Change += new exontrol.EXGAUGELib.exg2antt.ChangeEventHandler(this.exgauge1_Change); // DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); // MouseWheel event - Occurs when the mouse wheel moves while the control has focus private void exgauge1_MouseWheel(object sender,int Delta) { exgauge1.Value = exgauge1.FormatABC("A - B",exgauge1.Value,Delta,null); } //this.exgauge1.MouseWheel += new exontrol.EXGAUGELib.exg2antt.MouseWheelEventHandler(this.exgauge1_MouseWheel); exgauge1.BeginUpdate(); exgauge1.BackColor = Color.FromArgb(217,217,217); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Guage"; exgauge1.Layers.Count = 2; exgauge1.AllowSmoothChange = exontrol.EXGAUGELib.SmoothPropertyEnum.exSmoothChangeless; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[0]; var_Layer.RotateCenterY = "lheight/2 + 78"; var_Layer.Background.Picture.Name = "Guage_Background.png"; exontrol.EXGAUGELib.Layer var_Layer1 = exgauge1.Layers[1]; var_Layer1.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; var_Layer1.Background.Picture.Name = "Guage_Needle.png"; var_Layer1.RotateAngleValid = "value < 90 ? value : (value < 180 ? 90 : ( value < 270 ? 270 : value ))"; var_Layer1.RotateAngleToValue = "value >= 270 ? (value - 270)/90*50 : (value/90)*50 + 50"; var_Layer1.ValueToRotateAngle = "value < 50 ? (270 + value/50*90) : (value - 50)/50 * 90"; var_Layer1.RotateType = exontrol.EXGAUGELib.RotateTypeEnum.exRotateBilinearInterpolation; var_Layer1.set_Brightness(exontrol.EXGAUGELib.ColorAdjustmentChannelEnum.exAllChannels,0); exgauge1.Value = 78; exgauge1.EndUpdate(); |
27 |
How can I display a clock (rotate,wolf)
|
26 |
How can I display a clock (rotate,vintage)
|
25 |
How can I display a clock (rotate,london)
|
24 |
How can I display a clock (rotate)
|
23 |
How can I clip as a triangle
|
22 |
How can I limit the rotation from 0 to 360 degree, while dragging
// DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { // DragInfo.Debug = 483 // DragInfo.RotateAngleValid = "value < 0 ? 0 : (value > 360 ? 359.999999 : value)" } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers.Add("back"); var_Layer.RotateType = exontrol.EXGAUGELib.RotateTypeEnum.exRotateBilinearInterpolation; var_Layer.Left = "(width-512)/2"; var_Layer.Top = "(height-512)/2"; var_Layer.Height = 512.ToString(); var_Layer.Width = 512.ToString(); exontrol.EXGAUGELib.Picture var_Picture = var_Layer.Background.Picture; var_Picture.Value = "c:\\exontrol\\images\\card.png"; var_Picture.Left = "(width-pwidth)/2"; var_Picture.Top = "(height-pheight)/2"; var_Picture.Width = "pwidth"; var_Picture.Height = "pheight"; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; var_Layer.RotateAngle = -45; |
21 |
How can I clip as a pie
|
20 |
How can I use a picture to clip the layer
// Change event - Occurs when the layer's value is changed. private void exgauge1_Change(object sender,int Layer) { exgauge1.Layers["Clip"].Clip.Value = exgauge1.Layers["Thumb"].RotateAngle; } //this.exgauge1.Change += new exontrol.EXGAUGELib.exg2antt.ChangeEventHandler(this.exgauge1_Change); exgauge1.BeginUpdate(); exgauge1.PicturesPath = "C:\\Program Files\\Exontrol\\ExGauge\\Sample\\Design\\Circular\\Knob 1"; exgauge1.PicturesName = "`Layer` + int(value + 1) + `.png`"; exgauge1.Layers.Count = 5; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[4]; var_Layer.Key = "Thumb"; var_Layer.DefaultRotateAngle = -141; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; var_Layer.RotateType = exontrol.EXGAUGELib.RotateTypeEnum.exRotateBilinearInterpolation; exontrol.EXGAUGELib.Layer var_Layer1 = exgauge1.Layers[1]; var_Layer1.Key = "Clip"; exontrol.EXGAUGELib.Clip var_Clip = var_Layer1.Clip; var_Clip.Pie.SweepAngle = "value"; exontrol.EXGAUGELib.ClipPicture var_ClipPicture = var_Clip.Picture; var_ClipPicture.Name = exgauge1.Layers["Clip"].Background.Picture.Name; var_ClipPicture.AlphaTo = "128"; exgauge1.Layers["Thumb"].RotateAngle = 90; exgauge1.EndUpdate(); |
19 |
How do I clip a circle/ellipse
|
18 |
What InverseClip does
|
17 |
How do I clip as rectangle (round), from left to right
// Drag event - Notifies that the user drags the layer. private void exgauge1_Drag(object sender,exontrol.EXGAUGELib.DragInfo DragInfo) { // Me.Layers(0).Clip.Value = Me.FormatABC("(value + B) MIN 0 MAX 100", Me.Layers(0).UserData, DragInfo.DeltaX ) } //this.exgauge1.Drag += new exontrol.EXGAUGELib.exg2antt.DragEventHandler(this.exgauge1_Drag); // DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { // DragInfo.Debug= 287 exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[0]; var_Layer.UserData = var_Layer.Clip.Value; } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); // MouseWheel event - Occurs when the mouse wheel moves while the control has focus private void exgauge1_MouseWheel(object sender,int Delta) { exgauge1.Layers[0].Clip.Value = exgauge1.FormatABC("(value + B) MIN 0 MAX 100",exgauge1.Layers[0].Clip.Value,Delta,null); } //this.exgauge1.MouseWheel += new exontrol.EXGAUGELib.exg2antt.MouseWheelEventHandler(this.exgauge1_MouseWheel); exgauge1.Layers.Count = 1; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[0]; var_Layer.Left = "(width-128)/2"; var_Layer.Top = "(height-128)/2"; var_Layer.Height = 128.ToString(); var_Layer.Width = 128.ToString(); var_Layer.Background.Color.Value = Color.FromArgb(0,255,0); exontrol.EXGAUGELib.Clip var_Clip = var_Layer.Clip; exontrol.EXGAUGELib.ClipRoundRectangle var_ClipRoundRectangle = var_Clip.RoundRectangle; var_ClipRoundRectangle.Width = "value/100 * width"; var_ClipRoundRectangle.RoundRadiusX = "width/8"; var_ClipRoundRectangle.RoundRadiusY = "height/8"; var_Clip.Value = 50; |
16 |
How do I clip as rectangle, from bottom to top
|
15 |
How do I clip as rectangle, from top to bottom
// Drag event - Notifies that the user drags the layer. private void exgauge1_Drag(object sender,exontrol.EXGAUGELib.DragInfo DragInfo) { // Me.Layers(0).Clip.Value = Me.FormatABC("(value + B) MIN 0 MAX 100", Me.Layers(0).UserData, DragInfo.DeltaY ) } //this.exgauge1.Drag += new exontrol.EXGAUGELib.exg2antt.DragEventHandler(this.exgauge1_Drag); // DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { // DragInfo.Debug= 287 exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[0]; var_Layer.UserData = var_Layer.Clip.Value; } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); // MouseWheel event - Occurs when the mouse wheel moves while the control has focus private void exgauge1_MouseWheel(object sender,int Delta) { exgauge1.Layers[0].Clip.Value = exgauge1.FormatABC("(value + B) MIN 0 MAX 100",exgauge1.Layers[0].Clip.Value,Delta,null); } //this.exgauge1.MouseWheel += new exontrol.EXGAUGELib.exg2antt.MouseWheelEventHandler(this.exgauge1_MouseWheel); exgauge1.Layers.Count = 1; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[0]; var_Layer.Background.Picture.Value = "c:\\exontrol\\images\\card.png"; exontrol.EXGAUGELib.Clip var_Clip = var_Layer.Clip; var_Clip.Rectangle.Height = "value/100 * height"; var_Clip.Value = 50; |
14 |
How do I clip as rectangle, from right to left
|
13 |
How do I clip as rectangle, from left to right
// Drag event - Notifies that the user drags the layer. private void exgauge1_Drag(object sender,exontrol.EXGAUGELib.DragInfo DragInfo) { // Me.Layers(0).Clip.Value = Me.FormatABC("(value + B) MIN 0 MAX 100", Me.Layers(0).UserData, DragInfo.DeltaX ) } //this.exgauge1.Drag += new exontrol.EXGAUGELib.exg2antt.DragEventHandler(this.exgauge1_Drag); // DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { // DragInfo.Debug= 287 exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[0]; var_Layer.UserData = var_Layer.Clip.Value; } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); // MouseWheel event - Occurs when the mouse wheel moves while the control has focus private void exgauge1_MouseWheel(object sender,int Delta) { exgauge1.Layers[0].Clip.Value = exgauge1.FormatABC("(value + B) MIN 0 MAX 100",exgauge1.Layers[0].Clip.Value,Delta,null); } //this.exgauge1.MouseWheel += new exontrol.EXGAUGELib.exg2antt.MouseWheelEventHandler(this.exgauge1_MouseWheel); exgauge1.Layers.Count = 1; exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers[0]; var_Layer.Background.Picture.Value = "c:\\exontrol\\images\\card.png"; exontrol.EXGAUGELib.Clip var_Clip = var_Layer.Clip; var_Clip.Rectangle.Width = "value/100 * width"; var_Clip.Value = 50; |
12 |
How can I associate a value to rotation angle
// Change event - Occurs when the layer's value is changed. private void exgauge1_Change(object sender,int Layer) { exgauge1.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("`Value: <b>` + (value format ``) ",exgauge1.Layers[0].Value,null,null)); } //this.exgauge1.Change += new exontrol.EXGAUGELib.exg2antt.ChangeEventHandler(this.exgauge1_Change); // DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { // DragInfo.Debug = 483 } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers.Add("back"); var_Layer.RotateType = exontrol.EXGAUGELib.RotateTypeEnum.exRotateBilinearInterpolation; var_Layer.Left = "(width-512)/2"; var_Layer.Top = "(height-512)/2"; var_Layer.Height = 512.ToString(); var_Layer.Width = 512.ToString(); exontrol.EXGAUGELib.Picture var_Picture = var_Layer.Background.Picture; var_Picture.Value = "c:\\exontrol\\images\\card.png"; var_Picture.Left = "(width-pwidth)/2"; var_Picture.Top = "(height-pheight)/2"; var_Picture.Width = "pwidth"; var_Picture.Height = "pheight"; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; var_Layer.DefaultRotateAngle = 45; var_Layer.RotateCenterY = "lheight/2 + 32"; var_Layer.RotateCenterX = "lwidth/2 + 32"; var_Layer.RotateAngleToValue = "value/360 * 100"; var_Layer.ValueToRotateAngle = "value / 100 * 360"; var_Layer.Value = 50; |
11 |
How can I associate a value to vertical offset
// Change event - Occurs when the layer's value is changed. private void exgauge1_Change(object sender,int Layer) { exgauge1.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("`Value: <b>` + (value format ``)",exgauge1.Layers[0].Value,null,null)); } //this.exgauge1.Change += new exontrol.EXGAUGELib.exg2antt.ChangeEventHandler(this.exgauge1_Change); // DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { // DragInfo.Debug = 287 } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers.Add("back"); var_Layer.Background.Picture.Value = "c:\\exontrol\\images\\card.png"; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoMove; var_Layer.DefaultOffsetY = -100; var_Layer.OffsetYValid = "value MIN 0 MAX 200"; var_Layer.OffsetXValid = 0.ToString(); var_Layer.OffsetToValue = "offsety /200 * 100"; var_Layer.ValueToOffsetY = "value / 100 * 200"; var_Layer.Value = 50; |
10 |
How can I associate a value to horizontal offset
// Change event - Occurs when the layer's value is changed. private void exgauge1_Change(object sender,int Layer) { exgauge1.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("`Value: <b>` + (value format ``)",exgauge1.Layers[0].Value,null,null)); } //this.exgauge1.Change += new exontrol.EXGAUGELib.exg2antt.ChangeEventHandler(this.exgauge1_Change); // DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { // DragInfo.Debug = 287 } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers.Add("back"); var_Layer.Background.Picture.Value = "c:\\exontrol\\images\\card.png"; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoMove; var_Layer.DefaultOffsetX = -100; var_Layer.OffsetXValid = "value MIN 0 MAX 200"; var_Layer.OffsetYValid = 0.ToString(); var_Layer.OffsetToValue = "offsetx /200 * 100"; var_Layer.ValueToOffsetX = "value / 100 * 200"; var_Layer.Value = 50; |
9 |
How can I display the current angle
// Change event - Occurs when the layer's value is changed. private void exgauge1_Change(object sender,int Layer) { exgauge1.set_Caption(exontrol.EXGAUGELib.PropertyLayerCaptionEnum.exLayerCaption,exgauge1.FormatABC("`Angle: <b>` + (value format ``) + `°`",exgauge1.Layers[0].RotateAngle,null,null)); } //this.exgauge1.Change += new exontrol.EXGAUGELib.exg2antt.ChangeEventHandler(this.exgauge1_Change); // DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { // DragInfo.Debug = 483 } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers.Add("back"); var_Layer.RotateType = exontrol.EXGAUGELib.RotateTypeEnum.exRotateBilinearInterpolation; var_Layer.Left = "(width-512)/2"; var_Layer.Top = "(height-512)/2"; var_Layer.Height = 512.ToString(); var_Layer.Width = 512.ToString(); exontrol.EXGAUGELib.Picture var_Picture = var_Layer.Background.Picture; var_Picture.Value = "c:\\exontrol\\images\\card.png"; var_Picture.Left = "(width-pwidth)/2"; var_Picture.Top = "(height-pheight)/2"; var_Picture.Width = "pwidth"; var_Picture.Height = "pheight"; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; var_Layer.RotateAngleValid = "(value > 180 ? value - 360 : value) MIN 15 MAX 65"; |
8 |
How can I limit the rotation angle
|
7 |
Can I specify a different center while rotating
// DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { // DragInfo.Debug = 483 } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers.Add("back"); var_Layer.RotateType = exontrol.EXGAUGELib.RotateTypeEnum.exRotateBilinearInterpolation; var_Layer.Left = "(width-512)/2"; var_Layer.Top = "(height-512)/2"; var_Layer.Height = 512.ToString(); var_Layer.Width = 512.ToString(); exontrol.EXGAUGELib.Picture var_Picture = var_Layer.Background.Picture; var_Picture.Value = "c:\\exontrol\\images\\card.png"; var_Picture.Left = "(width-pwidth)/2"; var_Picture.Top = "(height-pheight)/2"; var_Picture.Width = "pwidth"; var_Picture.Height = "pheight"; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; var_Layer.RotateAngle = -45; var_Layer.RotateCenterY = "lheight/2 + 32"; var_Layer.RotateCenterX = "lwidth/2 + 32"; |
6 |
How can I rotate a layer, without cutting off the picture
// DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { // DragInfo.Debug = 483 } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers.Add("back"); var_Layer.Left = "(width-512)/2"; var_Layer.Top = "(height-512)/2"; var_Layer.Height = 512.ToString(); var_Layer.Width = 512.ToString(); exontrol.EXGAUGELib.Picture var_Picture = var_Layer.Background.Picture; var_Picture.Value = "c:\\exontrol\\images\\card.png"; var_Picture.Left = "(width-pwidth)/2"; var_Picture.Top = "(height-pheight)/2"; var_Picture.Width = "pwidth"; var_Picture.Height = "pheight"; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoRotate; var_Layer.RotateAngle = -45; |
5 |
How can I rotate a layer
|
4 |
Is there any way to debug the layer while moving
// DragStart event - Occurs once the user starts dragging a layer. private void exgauge1_DragStart(object sender,exontrol.EXGAUGELib.DragInfo DragInfo,ref bool Cancel) { // DragInfo.Debug = 287 } //this.exgauge1.DragStart += new exontrol.EXGAUGELib.exg2antt.DragStartEventHandler(this.exgauge1_DragStart); exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers.Add("back"); var_Layer.Background.Picture.Value = "c:\\exontrol\\images\\card.png"; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoMove; |
3 |
How do I specify where to move the layer, while dragging
exontrol.EXGAUGELib.Layer var_Layer = exgauge1.Layers.Add("back"); var_Layer.Background.Picture.Value = "c:\\exontrol\\images\\card.png"; var_Layer.OnDrag = exontrol.EXGAUGELib.OnDragLayerEnum.exDoMove; var_Layer.OffsetXValid = "int(value / 64) * 64"; var_Layer.OffsetYValid = "int(value / 64) * 64"; |
2 |
How can I add layers to the control
|
1 |
How can I add layers to the control
|