1. Trang chủ
  2. » Công Nghệ Thông Tin

AutoIT Help part 65 docx

6 309 0
Tài liệu đã được kiểm tra trùng lặp

Đang tải... (xem toàn văn)

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 6
Dung lượng 67,94 KB

Các công cụ chuyển đổi và chỉnh sửa cho tài liệu này

Nội dung

For other controls on reception of $GUI_EVENT_DROPPED, @GUI_DRAGID will return the controlID from where the drag start -1 if from a file, @GUI_DRAGFILE contain the filename being dropped

Trang 1

selected

If you want to set a treeview item as a default item which means painting it bold you can use $GUI_DEFBUTTON - to turn it off just use another value but

$GUI_DEFBUTTON, for instance 0 This state will not be returned by

GUICtrlGetState

If $GUI_DROPACCEPTED is set to a visible control a drag&drop can be taken in account The edit/input control will be set with the filename

For other controls on reception of $GUI_EVENT_DROPPED, @GUI_DRAGID will return the controlID from where the drag start (-1 if from a file,

@GUI_DRAGFILE contain the filename being dropped) and @GUI_DROPID returns the controlID of the dropped control

Only dragging a ListviewItem will start the drag & drop process The

@GUI_DRAGID will be the ListView controlID

Related

ColorMode (Option), GUICtrlCreate , GUICtrlSetData

Example

#include <GUIConstantsEx.au3>

Opt('MustDeclareVars', 1)

Example()

Func Example()

Local $msg

GUICreate("My GUI state") ; will create a dialog box that when displayed is centered

GUICtrlCreateLabel("my disable label", 10, 20)

GUICtrlSetState(-1, $GUI_DISABLE) ; the label is in disable state

GUICtrlCreateButton("my button", 50, 50)

GUICtrlSetState(-1, $GUI_FOCUS) ; the focus is on this button

Trang 2

GUISetState()

; Run the GUI until the dialog is closed

While 1

$msg = GUIGetMsg()

If $msg = $GUI_EVENT_CLOSE Then ExitLoop WEnd

EndFunc ;==>Example

Function Reference

GUICtrlSetStyle

thay đổi Style của control

GUICtrlSetStyle ( controlID, style [, exStyle] )

Parameters

controlID control id

style kiểu, xem GUI Control Styles Appendix exStyle kiểu mở rộng, xem Extended Style Table

Return Value

Success: Returns 1

Failure: Returns 0

Remarks

Trang 3

Some styles cannot be changed dynamically, check MSDN documentation

$CBS_UPPERCASE combo style is one example

Related

GUICtrlCreate

Example

#include <GUIConstantsEx.au3>

#include <StaticConstants.au3>

Opt('MustDeclareVars', 1)

Example()

Func Example()

Local $msg

GUICreate("My GUI style") ; will create a dialog box that when displayed is centered

GUICtrlCreateLabel("my label which will split on several lines", 10, 20, 100, 100)

GUICtrlSetStyle(-1, $SS_RIGHT)

GUISetState()

; Run the GUI until the dialog is closed

While 1

$msg = GUIGetMsg()

If $msg = $GUI_EVENT_CLOSE Then ExitLoop

WEnd

EndFunc ;==>Example

Trang 4

Function Reference

GUICtrlSetTip

đặt một đoạn căn bản sẽ hiện thị trên (bên ngoài) control khi để chuột đủ lâu trên control

GUICtrlSetTip ( controlID, tiptext [, "title" [, icon [, options]]]]] )

Parameters

controlID control id

tiptext đoạn văn bản

title tên tiêu đề (IE 5+)

icon

icon hiện thị (IE 5+)

0 = No icon

1 = Info icon (thông tin)

2 = Warning icon (cảnh báo)

3 = Error Icon (lỗi) options 1 = hiện thị kiểu Balloon Tip (IE 5+)

2 = căn giữa

Return Value

Success: Returns 1

Failure: Returns 0

Remarks

This tip text is displayed in a tooltip rectangular area

To skip an optional parameter, leaving it's default value intact, use the Default keyword

You may use @CR or @LF to create multi-line tooltips

The title, icon and Balloon Tip option all require Internet Explorer 5.0 or later in order to function

Trang 5

To display an icon, you must specify a non-empty title The icon appears on the same row as the title and thus requires a title to be present

Related

GUICtrlSet , Default

Example

#include <GUIConstantsEx.au3>

Opt('MustDeclareVars', 1)

Example()

Func Example()

Local $msg

GUICreate("My GUI control tip") ; will create a dialog box that when displayed

is centered

GUICtrlCreateLabel("my label", 10, 20)

GUICtrlSetTip(-1, "tip of my label")

GUISetState()

; Run the GUI until the dialog is closed

While 1

$msg = GUIGetMsg()

If $msg = $GUI_EVENT_CLOSE Then ExitLoop

WEnd

EndFunc ;==>Example

Function Reference

Ngày đăng: 02/07/2014, 17:21

TỪ KHÓA LIÊN QUAN

TÀI LIỆU CÙNG NGƯỜI DÙNG

TÀI LIỆU LIÊN QUAN