Xbasic

{CURSOR}

IN THIS PAGE

Syntax

{CURSOR= Cursor_Image }

Arguments

Cursor_Image

The name of cursor bitmap image. The following values are supported, in addition to any user defined or built-in bitmap. $sys_cursor_normal, $sys_cursor_ibeam, $sys_cursor_wait, $sys_cursor_cross, $sys_cursor_up, $sys_cursor_size, $sys_cursor_icon, $sys_cursor_sizenwse, $sys_cursor_sizenesw, $sys_cursor_sizewe, $sys_cursor_sizens, $sys_cursor_sizeall, $sys_cursor_icocur, $sys_cursor_no, $sys_cursor_hand, $sys_cursor_appstarting

Description

Allows you to specify a bitmap to use for the cursor when the mouse is over a control.

Discussion

The {CURSOR} command allows you to specify a bitmap to use for the cursor when the mouse is over a control. Applies to controls for which a flyover format string has been defined. To turn on a custom cursor insert the command {cursor= Cursor_Image } in the Xdialog before the controls for which the command will apply. To turn off the custom cursor, use the command {cursor=}.

Example

ui_dlg_box("Cursors",<<%dlg% 
When button 1 has focus, the standard cursor is used:; 
{cursor=} 
<%B=N;O={J=C,C}{C=Blue}{F=Tahoma,8,u}Button1;OF={J=C,C}{C=Light Blue}{F=Tahoma,8,U}Button1%!Button1_clicked>; 
{lf}; 
{lf}; 
{lf}; 
When button 2 has focus, the Windows 'hand' cursor is used:; 
{cursor=$sys_cursor_hand} 
<%B=N;O={J=C,C}{C=Blue}{F=Tahoma,8,u}Button2;OF={J=C,C}{C=Light Blue}{F=Tahoma,8,u}Button2%!Button2_clicked>; 
{lf}; 
{lf}; 
{lf}; 
When button 3 has focus, the Alpha Anywhere 'save' bitmap is used for the cursor:; 
{cursor=$a5_save} 
<%B=N;O={J=C,C}{C=Blue}{F=Tahoma,8,u}Button3;OF={J=C,C}{C=Light Blue}{F=Tahoma,8,u}Button3%!Button3_clicked>; 
%dlg%,<<%code% 
if left(a_dlg_button,6) = "button" then 
ui_msg_box("Event",a_dlg_button ) 
a_dlg_button = "" 
end if 
%code%)

Limitations

Desktop applications only

See Also