JochenAdministrator
(KiX Supporter)
2008-01-03 12:43 PM
KF Classic 2.47.4.0 : Is there any way to Hide the cursor?

As in the title ... I want to be able to not show any cursor on a kf form while the mouse is over.

Possible?


Benny69
(MM club member)
2008-01-03 02:47 PM
Re: KF Classic 2.47.4.0 : Is there any way to Hide the cursor?

Ok, I don't think this is possable in KF.Net but you are in luck with KF.Classic.

Unzip and put the attached .cur file at the root C: for this example, then run this code:

 Code:
;region Setup Variables
$Version = "Build(1.0.0.1)"
$System = CreateObject("Kixtart.System")
;endregion

Break on
If Not $System
   $= MessageBox("KiXforms Not Initiated. This Script Will Now Close.","Error",16)
   Quit()
EndIf

;region Main Form
$Form = $System.Form()
$Form.Cursor = "C:\Transparent Currsor.cur"
$Form.Text = "Basic Form $Version"
$Form.Size = 600,400
$Form.Left = $System.Screen.WorkingArea.Width - $Form.Width
$Form.Top = $System.Screen.WorkingArea.Height - $Form.Height
$Form.SysMenu = 0
$Form.Cursor = "C:\Transparent Currsor.cur"

; Clock
$CurrentTime=@Time
$Clock = $Form.Controls.Label($CurrentTime,10,15,55,20)
$Clock.Alignment=2
$Clock.Enabled=0
$Clock.BackColor=$Form.BackColor

$Close_Button = $Form.Controls.Button()
$Close_Button.Text = "CLose"
$Close_Button.OnClick = "Close_Button_Click()"
$Close_Button.Center

$Form.Show()

;region Startup
;call some function
;endregion

While $Form.Visible
	$Error = Execute($Form.DoEvents(1))
	$Clock.Text = @Time
Loop
Exit 0
;endregion

;region Startup Functions

;endregion

;region Common Functions
Function Close_Button_Click()
	Quit()
EndFunction
;endregion


The key part of the code is:
 Code:
$Form.Cursor = "C:\Transparent Currsor.cur"


JochenAdministrator
(KiX Supporter)
2008-01-03 02:51 PM
Re: KF Classic 2.47.4.0 : Is there any way to Hide the cursor?

Yes!!!

That was as well the only way I saw ... but hadn't had a transparent cursor at hand \:\)


JochenAdministrator
(KiX Supporter)
2008-01-03 02:53 PM
Re: KF Classic 2.47.4.0 : Is there any way to Hide the cursor?

Beautiful cursor \:\)

Not only not visible, but also totally transparent!


DrillSergeant
(MM club member)
2008-01-04 09:44 AM
Re: KF Classic 2.47.4.0 : Is there any way to Hide the cursor?

 Originally Posted By: Jochen
Not only not visible, but also totally transparent!


Were you drunk when you wrote this?


JochenAdministrator
(KiX Supporter)
2008-01-04 10:22 AM
Re: KF Classic 2.47.4.0 : Is there any way to Hide the cursor?

No I was just happy about my transparent cursor