~ubuntu-branches/ubuntu/maverick/ldtp/maverick

« back to all changes in this revision

Viewing changes to doc/pyldtp-doc.h

  • Committer: Bazaar Package Importer
  • Author(s): Kartik Mistry
  • Date: 2010-02-04 10:36:08 UTC
  • mfrom: (1.4.2 upstream)
  • mto: This revision was merged to the branch mainline in revision 19.
  • Revision ID: james.westby@ubuntu.com-20100204103608-dhqdo7jk10ygwt40
Tags: 2.0.2-1
* New upstream release:
  + Packaging is based on Ubuntu packages, Thanks Ubuntu!
  + LDTPv2 is a complete rewrite of LDTPv1 in Python
  + LTFX is completely removed in LDTP v2 in favor of wnck
* debian/control:
  + Updated to Standards-Version 3.8.4 (no changes needed)
  + Fixed typo in description python->Python
  + ldtp is now arch: all package
* debian/rules:
  + Using dh to make it simple
* Removed unused manpages
* Updated package to use new source format 3.0 (quilt)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/*
2
 
 * Linux Desktop Testing Project http://ldtp.freedesktop.org/
3
 
 *
4
 
 * Author
5
 
 *    Nagappan Alagappan <nagappan@gmail.com>
6
 
 *    Premkumar J <prem.jothimani@gmail.com>
7
 
 *
8
 
 * Copyright 2004 - 2007 Novell, Inc.
9
 
 * Copyright 2008 - 2009 Nagappan Alagappan
10
 
 *
11
 
 * Permission is granted to copy, distribute and/or modify this document
12
 
 * under the terms of the GNU Lesser General Public License, Version 2
13
 
 * or any later version published by the Free Software Foundation;
14
 
 * with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
15
 
 * A copy of the license is included in the section entitled "GNU
16
 
 * Lesser General Public License".
17
 
 *
18
 
 * You should have received a copy of the GNU GNU Lesser General Public
19
 
 * License along with this documentation; if not, write to the
20
 
 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
21
 
 * Boston, MA 02111-1307, USA.
22
 
 */
23
 
 
24
 
/** \mainpage LDTP User manual
25
 
 *
26
 
 * \section AboutLDTP About LDTP
27
 
 *
28
 
 * Linux Desktop Testing Project (LDTP) is aimed at producing high
29
 
 * quality test automation framework and cutting-edge tools that can
30
 
 * be used to test Linux Desktop and improve it. It uses the
31
 
 * Accessibility libraries to poke through the application's user
32
 
 * interface. The framework also has tools to record test-cases based
33
 
 * on user-selection on the application. For more information check
34
 
 * our site - http://ldtp.freedesktop.org
35
 
 *
36
 
 * \section scriptwritter Components list
37
 
 *
38
 
 * <TABLE align=left border=0 cellpadding=10 cellspacing=0>
39
 
 * <TR>
40
 
 * <TD>
41
 
 * \subpage calendar
42
 
 * </TD>
43
 
 * <TD>
44
 
 * \subpage calendarview
45
 
 * </TD>
46
 
 * <TD>
47
 
 * \subpage checkbox
48
 
 * </TD>
49
 
 * <TD>
50
 
 * \subpage checkmenuitem
51
 
 * </TD>
52
 
 * <TD>
53
 
 * \subpage combobox
54
 
 * </TD>
55
 
 * <TD>
56
 
 * \subpage embeddedcomponent
57
 
 * </TD>
58
 
 * </TR>
59
 
 * <TR>
60
 
 * <TD>
61
 
 * \subpage general
62
 
 * </TD>
63
 
 * <TD>
64
 
 * \subpage imaging
65
 
 * </TD>
66
 
 * <TD>
67
 
 * \subpage icon
68
 
 * </TD>
69
 
 * <TD>
70
 
 * \subpage label
71
 
 * </TD>
72
 
 * <TD>
73
 
 * \subpage layeredpane
74
 
 * </TD>
75
 
 * <TD>
76
 
 * \subpage list
77
 
 * </TD>
78
 
 * </TR>
79
 
 * <TR>
80
 
 * <TD>
81
 
 * \subpage logging
82
 
 * </TD>
83
 
 * <TD>
84
 
 * \subpage menuitem
85
 
 * </TD>
86
 
 * <TD>
87
 
 * \subpage pagetablist
88
 
 * </TD>
89
 
 * <TD>
90
 
 * \subpage panel
91
 
 * </TD>
92
 
 * <TD>
93
 
 * \subpage ProcessStatistics
94
 
 * </TD>
95
 
 * <TD>
96
 
 * \subpage pushbutton
97
 
 * </TD>
98
 
 * </TR>
99
 
 * <TR>
100
 
 * <TD>
101
 
 * \subpage radiobutton
102
 
 * </TD>
103
 
 * <TD>
104
 
 * \subpage radiomenuitem
105
 
 * </TD>
106
 
 * <TD>
107
 
 * \subpage scrollbar
108
 
 * </TD>
109
 
 * <TD>
110
 
 * \subpage slider
111
 
 * </TD>
112
 
 * <TD>
113
 
 * \subpage spinbutton
114
 
 * </TD>
115
 
 * <TD>
116
 
 * \subpage statusbar
117
 
 * </TD>
118
 
 * </TR>
119
 
 * <TR>
120
 
 * <TD>
121
 
 * \subpage table
122
 
 * </TD>
123
 
 * <TD>
124
 
 * \subpage text
125
 
 * </TD>
126
 
 * <TD>
127
 
 * \subpage togglebutton
128
 
 * </TD>
129
 
 * <TD>
130
 
 * \subpage toolbar
131
 
 * </TD>
132
 
 * <TD>
133
 
 * \subpage treetable
134
 
 * </TD>
135
 
 * <TD>
136
 
 * \subpage Window
137
 
 * </TD>
138
 
 * </TR>
139
 
 * <TR>
140
 
 * <TD>
141
 
 * \subpage LTFX
142
 
 * </TD>
143
 
 * </TR>
144
 
 * </TABLE>
145
 
 *
146
 
 * <a><img HEIGHT="30" src="../ldtp-logo-small.png" style="float:center;center:0px;top:0px;position:absolute;" alt="Linux Desktop Testing Project"/></a>
147
 
 *
148
 
 */
149
 
 
150
 
/** \page calendar calendar
151
 
 * \section CalendarSection About Calendar functions
152
 
 *
153
 
 * To operate on a calendar object and based on your requirement, you can use any of these functions
154
 
 *
155
 
 * \section CalendarAPI Calendar python API's
156
 
 * \subpage selectcalendardate - Select the given date in a calendar object
157
 
 *
158
 
 */
159
 
 
160
 
/** \page calendarview calendarview
161
 
 * \section CalendarViewSection About Calendar view functions
162
 
 *
163
 
 * To operate on a calendar view object and based on your requirement, you can use any of these functions
164
 
 *
165
 
 * \section CalendarViewAPI Calendar View python API's
166
 
 * \subpage enterstring - Generate keyboard events as if the user
167
 
 * types manually
168
 
 * \n
169
 
 * \n
170
 
 * \subpage selectevent - Select the calendar event based on event name
171
 
 * \n
172
 
 * \n
173
 
 * \subpage selecteventindex - Select the calendar event based on event index
174
 
 * \n
175
 
 * \n
176
 
 * \subpage verifyeventexist - Verify whether the calendar event exist
177
 
 * or not
178
 
 *
179
 
 */
180
 
 
181
 
/** \page checkbox checkbox
182
 
 * \section CheckboxSection About Checkbox functions
183
 
 *
184
 
 * To operate on a check box object and based on your requirement, you can use any of these functions
185
 
 *
186
 
 * \section CheckboxAPI Checkbox python API's
187
 
 *
188
 
 * \subpage check - Tick the check box
189
 
 * \n
190
 
 * \n
191
 
 * \subpage click - Click on the check box
192
 
 * \n
193
 
 * \n
194
 
 * \subpage stateenabled - Checks whether the check box is in enabled state or not
195
 
 * \n
196
 
 * \n
197
 
 * \subpage uncheck - Un tick the check box
198
 
 * \n
199
 
 * \n
200
 
 * \subpage verifycheck - Verify whether the check box is ticked
201
 
 * \n
202
 
 * \n
203
 
 * \subpage verifyuncheck - Verify whether the check box is unticked
204
 
 *
205
 
 */
206
 
 
207
 
/** \page checkmenuitem checkmenuitem
208
 
 * \section CheckmenuitemSection About Checkmenuitem functions
209
 
 *
210
 
 * To operate on a check menuitem object and based on your requirement, you can use any of these functions
211
 
 *
212
 
 * \section CheckmenuitemAPI Checkmenuitem python API's
213
 
 *
214
 
 * \subpage click - Click on the check menu item
215
 
 * \n
216
 
 * \n
217
 
 * \subpage menuitemenabled - Verify whether the check menu item is enabled
218
 
 * \n
219
 
 * \n
220
 
 * \subpage menucheck - Tick the menu item
221
 
 * \n
222
 
 * \n
223
 
 * \subpage menuuncheck - Un tick the menu item
224
 
 * \n
225
 
 * \n
226
 
 * \subpage selectmenuitem - Select the menu item
227
 
 * \n
228
 
 * \n
229
 
 * \subpage verifymenucheck - Verify whether the check menu item is ticked
230
 
 * \n
231
 
 * \n
232
 
 * \subpage verifymenuuncheck - Verify whether the check menu item is unticked
233
 
 *
234
 
 */
235
 
 
236
 
/** \page combobox combobox
237
 
 * \section ComboboxSection About Combobox functions
238
 
 *
239
 
 * To operate on a combobox object and based on your requirement, you can use any of these functions
240
 
 *
241
 
 * \section ComboboxAPI Combobox python API's
242
 
 *
243
 
 * \subpage capturetofile - Get the entires of list box and dump it to
244
 
 * a file
245
 
 * \n
246
 
 * \n
247
 
 * \subpage click - Click on a combo box
248
 
 * \n
249
 
 * \n
250
 
 * \subpage comboselect - Select an item from the combo box list or
251
 
 * menu item based on name
252
 
 * \n
253
 
 * \n
254
 
 * \subpage comboselectindex - Select an item from the combo box list or
255
 
 * menu item based on index
256
 
 * \n
257
 
 * \n
258
 
 * \subpage hidelist - Hide the combo box drop down list
259
 
 * \n
260
 
 * \n
261
 
 * \subpage selectindex - Select combo box item based on index
262
 
 * \n
263
 
 * \n
264
 
 * \subpage settextvalue - Set a text in the combo box list
265
 
 * \n
266
 
 * \n
267
 
 * \subpage showlist - Show the combo box drop down list
268
 
 * \n
269
 
 * \n
270
 
 * \subpage verifydropdown - Verify whether the drop down list pops up
271
 
 * \n
272
 
 * \n
273
 
 * \subpage verifyhidelist - Verify whether the drop down list is in
274
 
 * hidden state
275
 
 * \n
276
 
 * \n
277
 
 * \subpage verifyselect - Verify whether the item is selected in the
278
 
 * combo box list
279
 
 * \n
280
 
 * \n
281
 
 * \subpage verifysettext - Verify whether the text set is available
282
 
 * \n
283
 
 * \n
284
 
 * \subpage verifyshowlist - Verify whether the drop down list is
285
 
 * displayed
286
 
 *
287
 
 */
288
 
 
289
 
/** \page general general
290
 
 * \section GeneralSection About General functions
291
 
 *
292
 
 * General ldtp functions. Based on your requirement, you can use any of these functions
293
 
 *
294
 
 * \section GeneralAPI General python API's
295
 
 *
296
 
 * \subpage appundertest - Application under test
297
 
 * \n
298
 
 * \n
299
 
 * \subpage bindtext - Bind text to the current application and current locale
300
 
 * \n
301
 
 * \n
302
 
 * \subpage generatekeyevent - Generate keyboard event on currently
303
 
 * focused window
304
 
 * \n
305
 
 * \n
306
 
 * \subpage generatemouseevent - Generate mouse event based on x, y coordinates
307
 
 * \n
308
 
 * \n
309
 
 * \subpage getallstates - Get list of available states of an object
310
 
 * \n
311
 
 * \n
312
 
 * \subpage hasstate - Checks whether the object has a state
313
 
 * \n
314
 
 * \n
315
 
 * \subpage initappmap - Initialize application map
316
 
 * \n
317
 
 * \n
318
 
 * \subpage keypress - Generate keyboard press event
319
 
 * \n
320
 
 * \n
321
 
 * \subpage keyrelease - Generate keyboard press event
322
 
 * \n
323
 
 * \n
324
 
 * \subpage launchapp - Launch application
325
 
 * \n
326
 
 * \n
327
 
 * \subpage launchapp2 - Launch application
328
 
 * \n
329
 
 * \n
330
 
 * \subpage reinitldtp - Reinitialize LDTP
331
 
 * \n
332
 
 * \n
333
 
 * \subpage releasecontext - Release the context information
334
 
 * \n
335
 
 * \n
336
 
 * \subpage remap - Force remap the window information
337
 
 * \n
338
 
 * \n
339
 
 * \subpage setcontext - Set the context information
340
 
 * \n
341
 
 * \n
342
 
 * \subpage setlocale - Set locale to given locale
343
 
 * \n
344
 
 * \n
345
 
 * \subpage stopscriptengine - Stop LDTP script engine
346
 
 * \n
347
 
 * \n
348
 
 * \subpage wait - Suspend the operation for specified duration
349
 
 *
350
 
 */
351
 
 
352
 
/** \page imaging imaging
353
 
 * \section ImagingSection About Imaging functions
354
 
 *
355
 
 * To manipulate with image processing and based on your requirement, you can use any of these functions
356
 
 *
357
 
 * \section ImagingAPI Imaging python API's
358
 
 *
359
 
 * \subpage blackoutregion - Black out the specified region in the image
360
 
 * \n
361
 
 * \n
362
 
 * \subpage imagecapture - Capture the screen shot of a window
363
 
 * \n
364
 
 * \n
365
 
 * \subpage imagecompare - Compare two images
366
 
 *
367
 
 */
368
 
 
369
 
/** \page label label
370
 
 * \section LabelSection About Label functions
371
 
 *
372
 
 * To operate on a label object and based on your requirement, you can use any of these functions
373
 
 *
374
 
 * \section LabelAPI Label python API's
375
 
 *
376
 
 * \subpage getlabel - Get label of an object
377
 
 * \n
378
 
 * \n
379
 
 * \subpage getlabelatindex - Get label at the specified index in a window
380
 
 * \n
381
 
 * \n
382
 
 * \subpage selectlabelspanelbyname - Select the labels based on panel name
383
 
 *
384
 
 */
385
 
 
386
 
/** \page layeredpane layeredpane
387
 
 * \section LayeredpaneSection About Layeredpane functions
388
 
 *
389
 
 * To operate on a layered pane object and based on your requirement, you can use any of these functions
390
 
 *
391
 
 * \section LayeredpaneAPI Layeredpane python API's
392
 
 *
393
 
 * \subpage ischildindexselected - Is child selected in the complete
394
 
 * list based on index
395
 
 * \n
396
 
 * \n
397
 
 * \subpage ischilditemselected - Is child item selected in the
398
 
 * selected list based on name from the previously selected list
399
 
 * \n
400
 
 * \n
401
 
 * \subpage ischilditemindexselected - Is child item selected in the
402
 
 * selected list based on index from the previously selected list
403
 
 * \n
404
 
 * \n
405
 
 * \subpage ischildselected - Is child selected in the complete list
406
 
 * based on name
407
 
 * \n
408
 
 * \n
409
 
 * \subpage rightclick - Generate right click event
410
 
 * \n
411
 
 * \n
412
 
 * \subpage selectall - Select all the item
413
 
 * \n
414
 
 * \n
415
 
 * \subpage selectindex - Select item based on index
416
 
 * \n
417
 
 * \n
418
 
 * \subpage selectitem - Select an item
419
 
 * \n
420
 
 * \n
421
 
 * \subpage selecteditemcount - Selected item count
422
 
 * \n
423
 
 * \n
424
 
 * \subpage unselectall - Unselect all the item
425
 
 * \n
426
 
 * \n
427
 
 * \subpage unselectindex - Unselect item based on index
428
 
 * \n
429
 
 * \n
430
 
 * \subpage unselectitem - Unselect an item
431
 
 * \n
432
 
 * \n
433
 
 * \subpage unselectitemindex - Unselect item based on index from the
434
 
 * selected item
435
 
 *
436
 
 */
437
 
 
438
 
/** \page list list
439
 
 * \section ListSection About List functions
440
 
 *
441
 
 * To operate on a list object and based on your requirement, you can use any of these functions
442
 
 *
443
 
 * \section ListAPI List python API's
444
 
 *
445
 
 * \subpage selecttextitem - Select the item in the list based on name
446
 
 * \n
447
 
 * \n
448
 
 * \subpage selectindex - Select the item in the list based on index
449
 
 *
450
 
 */
451
 
 
452
 
/** \page logging logging
453
 
 * \section LoggingSection About Logging functions
454
 
 *
455
 
 * Log functions are used to log the operations performed. Output format of log file is XML file
456
 
 *
457
 
 * \section LoggingAPI Logging python API's
458
 
 *
459
 
 * \subpage addlogger - Add more logging handler
460
 
 * \n
461
 
 * \n
462
 
 * \subpage ldtplog - Log the operations in LDTP engine side
463
 
 * \n
464
 
 * \n
465
 
 * \subpage log - Log the operations
466
 
 * \n
467
 
 * \n
468
 
 * \subpage setloglevel - Set the level of logging
469
 
 * \n
470
 
 * \n
471
 
 * \subpage startldtplog - Start LDTP engine logging to a file
472
 
 * \n
473
 
 * \n
474
 
 * \subpage startlog - Start logging to a file
475
 
 * \n
476
 
 * \n
477
 
 * \subpage stopldtplog - Stop LDTP engine logging to a file
478
 
 * \n
479
 
 * \n
480
 
 * \subpage stoplog - Stop logging to a file
481
 
 *
482
 
 */
483
 
 
484
 
/** \page menuitem menuitem
485
 
 * \section MenuitemSection About Menuitem functions
486
 
 *
487
 
 * To operate on a menuitem object and based on your requirement, you can use any of these functions
488
 
 *
489
 
 * \section MenuitemAPI Menuitem python API's
490
 
 *
491
 
 * \subpage click - Click on the menu item
492
 
 * \n
493
 
 * \n
494
 
 * \subpage doesmenuitemexist - Check whether a menu item exist
495
 
 * \n
496
 
 * \n
497
 
 * \subpage invokemenu - Invoke a menu in embedded component
498
 
 * \n
499
 
 * \n
500
 
 * \subpage listsubmenus - Get list of menu items under a menu
501
 
 * \n
502
 
 * \n
503
 
 * \subpage selectmenuitem - Select the given menu item
504
 
 *
505
 
 */
506
 
 
507
 
/** \page panel panel
508
 
 * \section PanelSection About Panel functions
509
 
 *
510
 
 * To operate on a panel object and based on your requirement, you can use any of these functions
511
 
 *
512
 
 * \section PanelAPI Panel python API's
513
 
 *
514
 
 * \subpage getpanelchildcount - Get the number of children under a panel
515
 
 * \n
516
 
 * \n
517
 
 * \subpage selectpanel - Select panel based on index
518
 
 * \n
519
 
 * \n
520
 
 * \subpage selectpanelname - Select panel based on name
521
 
 *
522
 
 */
523
 
 
524
 
/** \page ProcessStatistics ProcessStatistics
525
 
 * \section ProcessStatisticsSection About Process Statistics functions
526
 
 *
527
 
 * To monitor the CPU and memory utilization you can use this class
528
 
 *
529
 
 * \section ProcessStatisticsAPI  Process Statistics python API's
530
 
 *
531
 
 * \subpage Classpstats - Python class to monitor CPU / Memory utilization
532
 
 *
533
 
 */
534
 
 
535
 
/** \page pushbutton pushbutton
536
 
 * \section PushbuttonSection About Pushbutton functions
537
 
 *
538
 
 * To operate on a push button object and based on your requirement, you can use any of these functions
539
 
 *
540
 
 * \section PushbuttonAPI Pushbutton python API's
541
 
 *
542
 
 * \subpage click - Generates mouse left click event on the object
543
 
 * \n
544
 
 * \n
545
 
 * \subpage mouseleftclick - Generate mouse left click event
546
 
 * \n
547
 
 * \n
548
 
 * \subpage stateenabled - Checks whether the push button is in
549
 
 * enabled state
550
 
 * \n
551
 
 * \n
552
 
 * \subpage verifypushbutton - Verify whether the object is a push button
553
 
 *
554
 
 */
555
 
 
556
 
/** \page radiobutton radiobutton
557
 
 * \section RadiobuttonSection About Radiobutton functions
558
 
 *
559
 
 * To operate on a radio button object and based on your requirement, you can use any of these functions
560
 
 *
561
 
 * \section RadiobuttonAPI Radiobutton python API's
562
 
 *
563
 
 * \subpage click - Click on a radio button
564
 
 * \n
565
 
 * \n
566
 
 * \subpage check - Select the radio button
567
 
 * \n
568
 
 * \n
569
 
 * \subpage stateenabled - Checks whether the radio button is in
570
 
 * enabled state or not
571
 
 * \n
572
 
 * \n
573
 
 * \subpage verifycheck - Verify whether the radio button is selected
574
 
 * \n
575
 
 * \n
576
 
 * \subpage verifyuncheck - Verify whether the radio button is deselected
577
 
 *
578
 
 */
579
 
 
580
 
/** \page radiomenuitem radiomenuitem
581
 
 * \section RadiomenuitemSection About Radiomenuitem functions
582
 
 *
583
 
 * To operate on a radio menuitem object and based on your requirement, you can use any of these functions
584
 
 *
585
 
 * \section RadiomenuitemAPI Radiomenuitem python API's
586
 
 *
587
 
 * \subpage click - Click on a radio menu item
588
 
 * \n
589
 
 * \n
590
 
 * \subpage menuitemenabled - Verify whether the radio menu item is enabled
591
 
 * \n
592
 
 * \n
593
 
 * \subpage menucheck - Select the radio menu item
594
 
 * \n
595
 
 * \n
596
 
 * \subpage selectmenuitem - Select the radio menu item
597
 
 * \n
598
 
 * \n
599
 
 * \subpage verifymenucheck - Verify whether the radio menu item is selected
600
 
 * \n
601
 
 * \n
602
 
 * \subpage verifymenuuncheck - Verify whether the radio menu item is deselected
603
 
 *
604
 
 */
605
 
 
606
 
/** \page scrollbar scrollbar
607
 
 * \section ScrollbarSection About Scrollbar functions
608
 
 *
609
 
 * To operate on a scrollbar object and based on your requirement, you can use any of these functions
610
 
 *
611
 
 * \section ScrollbarAPI Scrollbar python API's
612
 
 *
613
 
 * \subpage onedown - Scroll down one time
614
 
 * \n
615
 
 * \n
616
 
 * \subpage oneleft - Scroll left one time
617
 
 * \n
618
 
 * \n
619
 
 * \subpage oneright - Scroll right one time
620
 
 * \n
621
 
 * \n
622
 
 * \subpage oneup - Scroll up one time
623
 
 * \n
624
 
 * \n
625
 
 * \subpage scrolldown - Scroll down
626
 
 * \n
627
 
 * \n
628
 
 * \subpage scrollleft - Scroll left
629
 
 * \n
630
 
 * \n
631
 
 * \subpage scrollright - Scroll right
632
 
 * \n
633
 
 * \n
634
 
 * \subpage scrollup - Scroll up
635
 
 * \n
636
 
 * \n
637
 
 * \subpage verifyscrollbar - Verify whether the object is scroll bar
638
 
 * \n
639
 
 * \n
640
 
 * \subpage verifyscrollbarhorizontal - Verify whether the object is
641
 
 * horizontal scroll bar
642
 
 * \n
643
 
 * \n
644
 
 * \subpage verifyscrollbarvertical - Verify whether the object is
645
 
 * vertical scroll bar
646
 
 *
647
 
 */
648
 
 
649
 
/** \page slider slider
650
 
 * \section SliderSection About Slider functions
651
 
 *
652
 
 * To operate on a slider object and based on your requirement, you can use any of these functions
653
 
 *
654
 
 * \section SliderAPI Slider python API's
655
 
 *
656
 
 * \subpage decrease - Decrease the slider
657
 
 * \n
658
 
 * \n
659
 
 * \subpage getminincrement - Get min increment value of slider
660
 
 * \n
661
 
 * \n
662
 
 * \subpage getslidervalue - Get the slider value
663
 
 * \n
664
 
 * \n
665
 
 * \subpage increase - Increase the slider
666
 
 * \n
667
 
 * \n
668
 
 * \subpage setmax - Set the slider to max value
669
 
 * \n
670
 
 * \n
671
 
 * \subpage setmin - Set the slider to min value
672
 
 * \n
673
 
 * \n
674
 
 * \subpage verifyslider - Verify whether the object is slider
675
 
 * \n
676
 
 * \n
677
 
 * \subpage verifysliderhorizontal - Verify whether the object is
678
 
 * horizontal slider
679
 
 * \n
680
 
 * \n
681
 
 * \subpage verifyslidervertical - Verify whether the object is
682
 
 * vertical slider
683
 
 *
684
 
 */
685
 
 
686
 
/** \page spinbutton spinbutton
687
 
 * \section SpinbuttonSection About Spinbutton functions
688
 
 *
689
 
 * To operate on a spin button object and based on your requirement, you can use any of these functions
690
 
 *
691
 
 * \section SpinbuttonAPI Spinbutton python API's
692
 
 *
693
 
 * \subpage getvalue - Get value from spin button
694
 
 * \n
695
 
 * \n
696
 
 * \subpage getmaxvalue - Get max value of spin button
697
 
 * \n
698
 
 * \n
699
 
 * \subpage getminincrement - Get min increment value of spin button
700
 
 * \n
701
 
 * \n
702
 
 * \subpage getminvalue - Get min value of spin button
703
 
 * \n
704
 
 * \n
705
 
 * \subpage setvalue - Set value in spin button
706
 
 * \n
707
 
 * \n
708
 
 * \subpage verifysetvalue - Verify the value of spin button with the
709
 
 * given value
710
 
 *
711
 
 */
712
 
 
713
 
/** \page pagetablist pagetablist
714
 
 * \section PagetabSection About Pagetab functions
715
 
 *
716
 
 * To operate on a page tab object and based on your requirement, you can use any of these functions
717
 
 *
718
 
 * \section PagetabAPI Pagetab python API's
719
 
 *
720
 
 * \subpage gettabcount - Get number of tabs in a page tab list
721
 
 * \n
722
 
 * \n
723
 
 * \subpage gettabname - Get name of a tab in the page tab list
724
 
 * \n
725
 
 * \n
726
 
 * \subpage selecttab - Select tab based on tab name
727
 
 * \n
728
 
 * \n
729
 
 * \subpage selecttabindex - Select tab based on tab index
730
 
 *
731
 
 */
732
 
 
733
 
/** \page statusbar statusbar
734
 
 * \section StatusbarSection About Statusbar functions
735
 
 *
736
 
 * To operate on a status bar object and based on your requirement, you can use any of these functions
737
 
 *
738
 
 * \section PagetabAPI Pagetab python API's
739
 
 *
740
 
 * \subpage getstatusbartext - Get text displayed in status bar
741
 
 * \n
742
 
 * \n
743
 
 * \subpage verifystatusbar - Verify the status bar text with the
744
 
 * given text
745
 
 * \n
746
 
 * \n
747
 
 * \subpage verifystatusbarvisible - Verify whether the status bar
748
 
 * object is visible
749
 
 *
750
 
 */
751
 
 
752
 
/** \page table table
753
 
 * \section TableSection About Table functions
754
 
 *
755
 
 * To operate on a table object and based on your requirement, you can use any of these functions
756
 
 *
757
 
 * \section TableAPI Table python API's
758
 
 *
759
 
 * \subpage checkrow - Tick the table cell row of type toggle button
760
 
 * \n
761
 
 * \n
762
 
 * \subpage doesrowexist - Checks whether the row with the given name exist
763
 
 * \n
764
 
 * \n
765
 
 * \subpage doubleclick - Generate double click event on the component
766
 
 * \n
767
 
 * \n
768
 
 * \subpage doubleclickrow - Generate double click event on the row
769
 
 * with matches the given name
770
 
 * \n
771
 
 * \n
772
 
 * \subpage getcellvalue - Get the table cell value
773
 
 * \n
774
 
 * \n
775
 
 * \subpage getrowcount - Get the rows count
776
 
 * \n
777
 
 * \n
778
 
 * \subpage gettablerowindex - Get the index of the row, where the
779
 
 * given name matches
780
 
 * \n
781
 
 * \n
782
 
 * \subpage selectlastrow - Select last row in the table
783
 
 * \n
784
 
 * \n
785
 
 * \subpage selectrow - Select a row with the given name
786
 
 * \n
787
 
 * \n
788
 
 * \subpage selectrowindex - Select a row with an index
789
 
 * \n
790
 
 * \n
791
 
 * \subpage selectrowpartialmatch - Select a row with the given
792
 
 * partial name
793
 
 * \n
794
 
 * \n
795
 
 * \subpage setcellvalue - Set the table cell value with the given value
796
 
 * \n
797
 
 * \n
798
 
 * \subpage singleclickrow - Generate single click event on the row
799
 
 * with matches the given name
800
 
 * \n
801
 
 * \n
802
 
 * \subpage sortcolumn - Sort the column based on the given field name
803
 
 * \n
804
 
 * \n
805
 
 * \subpage sortcolumnindex - Sort the column based on the given field index
806
 
 * \n
807
 
 * \n
808
 
 * \subpage uncheckrow - Un check the table cell of type toggle button
809
 
 * \n
810
 
 * \n
811
 
 * \subpage verifytablecell - Verify whether the cell value is same as
812
 
 * the given value
813
 
 * \n
814
 
 * \n
815
 
 * \subpage verifypartialtablecell - Verify whether the cell value
816
 
 * partially matches the given value
817
 
 *
818
 
 */
819
 
 
820
 
/** \page text text
821
 
 * \section TextSection About Text functions
822
 
 *
823
 
 * To operate on a text object and based on your requirement, you can use any of these functions
824
 
 *
825
 
 * \section TextAPI Text python API's
826
 
 *
827
 
 * \subpage activatetext - Activate the text
828
 
 * \n
829
 
 * \n
830
 
 * \subpage appendtext - Append the given text to the existing text
831
 
 * \n
832
 
 * \n
833
 
 * \subpage comparetextproperty - Checks the availability of all the given text property
834
 
 * \n
835
 
 * \n
836
 
 * \subpage containstextproperty - Checks the availability of one given text property
837
 
 * \n
838
 
 * \n
839
 
 * \subpage copytext - Copy text to clipboard
840
 
 * \n
841
 
 * \n
842
 
 * \subpage cuttext - Cut the text
843
 
 * \n
844
 
 * \n
845
 
 * \subpage deletetext - Deletes the text
846
 
 * \n
847
 
 * \n
848
 
 * \subpage enterstring - Genereate keyboard events as if user key-ins
849
 
 * \n
850
 
 * \n
851
 
 * \subpage getcharcount - Get the number of characters present in a
852
 
 * text field
853
 
 * \n
854
 
 * \n
855
 
 * \subpage getcursorposition - Get the current cursor position
856
 
 * \n
857
 
 * \n
858
 
 * \subpage gettextproperty - Get the properties of text
859
 
 * \n
860
 
 * \n
861
 
 * \subpage gettextvalue - Get the text content
862
 
 * \n
863
 
 * \n
864
 
 * \subpage grabfocus - Grab the focus
865
 
 * \n
866
 
 * \n
867
 
 * \subpage inserttext - Insert a text in specified location
868
 
 * \n
869
 
 * \n
870
 
 * \subpage istextstateenabled - Verify whether the text field is enabled
871
 
 * \n
872
 
 * \n
873
 
 * \subpage mouseleftclick - Generate mouse left click event
874
 
 * \n
875
 
 * \n
876
 
 * \subpage mouserightclick - Generate mouse right click event
877
 
 * \n
878
 
 * \n
879
 
 * \subpage mousemove - Simulate mouse move event
880
 
 * \n
881
 
 * \n
882
 
 * \subpage pastetext - Paste the text from clip board to the text area
883
 
 * \n
884
 
 * \n
885
 
 * \subpage rightclick - Generate right click event
886
 
 * \n
887
 
 * \n
888
 
 * \subpage selecttextbyindexandregion - Select text by index and region
889
 
 * \n
890
 
 * \n
891
 
 * \subpage selecttextbyname - Select text by the given name
892
 
 * \n
893
 
 * \n
894
 
 * \subpage setcursorposition - Move the cursor position to the
895
 
 * specified location
896
 
 * \n
897
 
 * \n
898
 
 * \subpage settextvalue - Sets the text value in the text field
899
 
 * \n
900
 
 * \n
901
 
 * \subpage verifypartialmatch - Verify whether the given text
902
 
 * partially matches with the existing text
903
 
 * \n
904
 
 * \n
905
 
 * \subpage verifysettext - Verify whether the given text is same as
906
 
 * the text available in the text field
907
 
 *
908
 
 */
909
 
 
910
 
/** \page togglebutton togglebutton
911
 
 * \section TogglebuttonSection About Togglebutton functions
912
 
 *
913
 
 * To operate on a toggle object and based on your requirement, you can use any of these functions
914
 
 *
915
 
 * \section TogglebuttonAPI Togglebutton python API's
916
 
 *
917
 
 * \subpage click - Click on a toggle button
918
 
 * \n
919
 
 * \n
920
 
 * \subpage enterstring - Generate keyboard event as if user keys-in
921
 
 * \n
922
 
 * \n
923
 
 * \subpage press - Toggle's the button state
924
 
 * \n
925
 
 * \n
926
 
 * \subpage stateenabled - Checks whether the toggle button is in
927
 
 * enabled state or not
928
 
 * \n
929
 
 * \n
930
 
 * \subpage verifytoggled - Verify whether the button is in toggled state
931
 
 *
932
 
 */
933
 
 
934
 
/** \page embeddedcomponent embeddedcomponent
935
 
 * \section EmbeddedcomponentSection About Embeddedcomponent functions
936
 
 *
937
 
 * To operate on a embedded component (accessible) object and based on your requirement, you can use any of these functions
938
 
 *
939
 
 * \section EmbeddedcomponentAPI Embeddedcomponent python API's
940
 
 *
941
 
 * \subpage click - Click on an embedded component object
942
 
 * \n
943
 
 * \n
944
 
 * \subpage enterstring - Generate keyboard event as if user keys-in
945
 
 * \n
946
 
 * \n
947
 
 * \subpage invokemenu - Invokes the menu in an embedded component object
948
 
 * \n
949
 
 * \n
950
 
 * \subpage rightclick - Right clicks on an embedded component object
951
 
 *
952
 
 */
953
 
 
954
 
/** \page toolbar toolbar
955
 
 * \section ToolbarSection About Toolbar functions
956
 
 *
957
 
 * To operate on a toolbar object and based on your requirement, you can use any of these functions
958
 
 *
959
 
 * \section ToolbarAPI Toolbar python API's
960
 
 *
961
 
 * \subpage verifybuttoncount - Verify the number of buttons matches
962
 
 * with the given button count
963
 
 * \n
964
 
 * \n
965
 
 * \subpage verifyvisiblebuttoncount - Verify the visible number of
966
 
 * buttons matches the given button count
967
 
 *
968
 
 */
969
 
 
970
 
/** \page treetable treetable
971
 
 * \section TreetableSection About Treetable functions
972
 
 *
973
 
 * To operate on a tree table object and based on your requirement, you can use any of these functions
974
 
 *
975
 
 * \section TreetableAPI Treetable python API's
976
 
 *
977
 
 * \subpage checkrow - Tick the table cell row of type toggle button
978
 
 * \n
979
 
 * \n
980
 
 * \subpage doesrowexist - Checks whether the row with the given name exist
981
 
 * \n
982
 
 * \n
983
 
 * \subpage doubleclick - Generate double click event on the component
984
 
 * \n
985
 
 * \n
986
 
 * \subpage doubleclickrow - Generate double click event on the row
987
 
 * which matches the given name
988
 
 * \n
989
 
 * \n
990
 
 * \subpage doubleclickrowindex - Generate double click event on the row
991
 
 * which matches the given index
992
 
 * \n
993
 
 * \n
994
 
 * \subpage expandtablecell - Expand or collapse tree table
995
 
 * \n
996
 
 * \n
997
 
 * \subpage getcellvalue - Get the table cell value
998
 
 * \n
999
 
 * \n
1000
 
 * \subpage getrowcount - Get the rows count
1001
 
 * \n
1002
 
 * \n
1003
 
 * \subpage gettreetablerowindex - Get the index of the row, where the
1004
 
 * given name matches
1005
 
 * \n
1006
 
 * \n
1007
 
 * \subpage rightclick - Generate right click event
1008
 
 * \n
1009
 
 * \n
1010
 
 * \subpage selectlastrow - Select last row in the table
1011
 
 * \n
1012
 
 * \n
1013
 
 * \subpage selectrow - Select a row with the given name
1014
 
 * \n
1015
 
 * \n
1016
 
 * \subpage selectrowindex - Select a row with an index
1017
 
 * \n
1018
 
 * \n
1019
 
 * \subpage selectrowpartialmatch - Select a row with the given
1020
 
 * partial name
1021
 
 * \n
1022
 
 * \n
1023
 
 * \subpage setcellvalue - Set the table cell value with the given value
1024
 
 * \n
1025
 
 * \n
1026
 
 * \subpage singleclickrow - Generate single click event on the row
1027
 
 * with matches the given name
1028
 
 * \n
1029
 
 * \n
1030
 
 * \subpage sortcolumn - Sort the column based on the given field name
1031
 
 * \n
1032
 
 * \n
1033
 
 * \subpage sortcolumnindex - Sort the column based on the given field index
1034
 
 * \n
1035
 
 * \n
1036
 
 * \subpage uncheckrow - Un check the table cell of type toggle button
1037
 
 * \n
1038
 
 * \n
1039
 
 * \subpage verifycheckrow - Verify whether the table cell of type
1040
 
 * toggle button is ticked
1041
 
 * \n
1042
 
 * \n
1043
 
 * \subpage verifytablecell - Verify whether the cell value is same as
1044
 
 * the given value
1045
 
 * \n
1046
 
 * \n
1047
 
 * \subpage verifypartialtablecell - Verify whether the cell value
1048
 
 * partially matches the given value
1049
 
 * \n
1050
 
 * \n
1051
 
 * \subpage verifyuncheckrow - Verify whether the table cell of type
1052
 
 * toggle button is un-ticked
1053
 
 *
1054
 
 */
1055
 
 
1056
 
/** \page Window Window functions
1057
 
 * \section WindowSection About Window functions
1058
 
 *
1059
 
 * Window based functions
1060
 
 * \n
1061
 
 * \n
1062
 
 *
1063
 
 * \section WindowAPI Window python API's
1064
 
 *
1065
 
 * \subpage activatewindow - Activate the given window name or all
1066
 
 * open windows
1067
 
 * \n
1068
 
 * \n
1069
 
 * \subpage closewindow - Close the given window name or all
1070
 
 * open windows
1071
 
 * \n
1072
 
 * \n
1073
 
 * \subpage getapplist - Get list of accessibility enabled applications
1074
 
 * \n
1075
 
 * \n
1076
 
 * \subpage getchild - Get child object of a window which matches label or role name or both
1077
 
 * \n
1078
 
 * \n
1079
 
 * \subpage getobjectinfo - Get list of available property classes of an object
1080
 
 * \n
1081
 
 * \n
1082
 
 * \subpage getobjectlist - Get list of objects in a window
1083
 
 * \n
1084
 
 * \n
1085
 
 * \subpage getobjectproperty - Get a class (label, type) property of an object
1086
 
 * \n
1087
 
 * \n
1088
 
 * \subpage getwindowlist - Get current list of window titles
1089
 
 * \n
1090
 
 * \n
1091
 
 * \subpage getwindowsize - Get size of the given window title
1092
 
 * \n
1093
 
 * \n
1094
 
 * \subpage getobjectsize - Get size of the given object
1095
 
 * \n
1096
 
 * \n
1097
 
 * \subpage guiexist - Checks whether a window exist
1098
 
 * \n
1099
 
 * \n
1100
 
 * \subpage guitimeout - Modifies the global gui timeout period
1101
 
 * \n
1102
 
 * \n
1103
 
 * \subpage maximizewindow - Maximize the given window name or all
1104
 
 * open windows
1105
 
 * \n
1106
 
 * \n
1107
 
 * \subpage minimizewindow - Minimize the given window name or all
1108
 
 * open windows
1109
 
 * \n
1110
 
 * \n
1111
 
 * \subpage objectexist - To check whether a component exist in a given window
1112
 
 * \n
1113
 
 * \n
1114
 
 * \subpage objtimeout - Modifies the global object timeout period
1115
 
 * \n
1116
 
 * \n
1117
 
 * \subpage onwindowcreate - Register callback function to be called
1118
 
 * when the specified window is created
1119
 
 * \n
1120
 
 * \n
1121
 
 * \subpage removecallback - Remove the registered callback function using onwindowcreate
1122
 
 * \n
1123
 
 * \n
1124
 
 * \subpage waittillguiexist - Suspend the operation till the window exist
1125
 
 * \n
1126
 
 * \n
1127
 
 * \subpage waittillguinotexist - Suspend the operation till the
1128
 
 * window quits
1129
 
 *
1130
 
 */
1131
 
 
1132
 
/** \page LTFX LTFX functions
1133
 
 * \section LTFXSection About LTFX functions
1134
 
 *
1135
 
 * To operate on an window in which accessibility is not enabled we
1136
 
 * use external application Linux Test For X (In short LTFX) -
1137
 
 * http://sf.net/projects/ltfx
1138
 
 * \n
1139
 
 *
1140
 
 * \section LTFXAPI LTFX python API's
1141
 
 *
1142
 
 * \subpage activatewin - Activate the window with the given title
1143
 
 * \n
1144
 
 * \n
1145
 
 * \subpage activatewinpartialname - Activate the window with the
1146
 
 * given partial title
1147
 
 * \n
1148
 
 * \n
1149
 
 * \subpage getactivewin - Get the window title thats currently in focus
1150
 
 * \n
1151
 
 * \n
1152
 
 * \subpage partialexists - Check the window whether it exist based on
1153
 
 * the partial given title
1154
 
 * \n
1155
 
 * \n
1156
 
 * \subpage typekey - Generate keyboard events as if user key in
1157
 
 * \n
1158
 
 * \n
1159
 
 * \subpage waitwinname - Wait for window to appear with the given title
1160
 
 * \n
1161
 
 * \n
1162
 
 * \subpage waitwinpartialname - Wait for window to appear with the
1163
 
 * given partial title
1164
 
 * \n
1165
 
 * \n
1166
 
 * \subpage windowexists - Check the window whether it exist based on
1167
 
 * the given title
1168
 
 * \n
1169
 
 *
1170
 
 * \section LTFXAssumptions Assumptions
1171
 
 *
1172
 
 * LTFX functions assumes that the window to be operated is in
1173
 
 * focus. It directly generates the X key board events. It does not
1174
 
 * know whether the object exist or the operation is successfully
1175
 
 * done.
1176
 
 *
1177
 
 */
1178
 
 
1179
 
/** \page icon icon
1180
 
 * \section IconSection About Icon functions
1181
 
 *
1182
 
 * To operate on an icon object
1183
 
 *
1184
 
 * \section IconAPI Icon python API's
1185
 
 *
1186
 
 * \subpage rightclick - Generate right click event
1187
 
 *
1188
 
 */
1189
 
 
1190
 
/**
1191
 
 * \page initappmap initappmap
1192
 
 * \section Syntax
1193
 
 * 
1194
 
 * initappmap ('\<application map name\>')
1195
 
 * 
1196
 
 * \section Description
1197
 
 * 
1198
 
 * Application map will be loaded
1199
 
 * 
1200
 
 * Refer:
1201
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
1202
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/appmap.c
1203
 
 * 
1204
 
 * \section Example
1205
 
 * 
1206
 
 * from ldtp import *
1207
 
 * 
1208
 
 * initappmap ('nautilus.map')
1209
 
 * 
1210
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1211
 
 */
1212
 
 
1213
 
/**
1214
 
 * \page guiexist guiexist
1215
 
 * \section Syntax
1216
 
 * 
1217
 
 * guiexist ('\<window name\>'[, \<object name\>])
1218
 
 * 
1219
 
 * \section Description
1220
 
 * 
1221
 
 * If the given window name exist, this function returns 1. If window doesnot exist, then this function returns 0.
1222
 
 * 
1223
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
1224
 
 * 
1225
 
 * \section ImplementationDetails
1226
 
 * 
1227
 
 * \retval 1 on success and 0 on no existing window
1228
 
 * 
1229
 
 * \section Example
1230
 
 * 
1231
 
 * With respect to gedit Open dialog
1232
 
 *
1233
 
 * from ldtp import *
1234
 
 *
1235
 
 * # if GTK File selector is opened the following function will return 1, else 0
1236
 
 *
1237
 
 * guiexist ('dlgOpenFile...')
1238
 
 * 
1239
 
 * guiexist ('dlgOpenFile...', 'btnOpen') # Returns 1, If window exist and also the object exist
1240
 
 * 
1241
 
 * guiexist ('dlgOpenFile...', 'btnabc') # Returns 0
1242
 
 * 
1243
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1244
 
 */
1245
 
 
1246
 
/**
1247
 
 * \page waittillguiexist waittillguiexist
1248
 
 * \section Syntax
1249
 
 * 
1250
 
 * waittillguiexist ('\<window name\>'[, '\<component name\>'[, guiTimeOut]])
1251
 
 * 
1252
 
 * \section Description
1253
 
 * 
1254
 
 * If the given window name exist, this function returns 1. If window doesnot exist, then this function returns 0. Difference between \ref guiexist and waitguiexist is, waitguiexist waits for maximum 30 seconds. Still the window doesn't appear, then 0 is returned. We can set the environment variable 'GUI_TIMEOUT' to change the default waiting time. We can wait for component also and its an optional argument. The default value of guiTimeOut is None and it can be changed either by environment variable or by passing an integer argument > 0. This timeout will be for this specific window and it will not affect the global default time out settings. If you want to change the global default time out settings use guitimeout or objtimeout function appropriately.
1255
 
 * 
1256
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
1257
 
 * 
1258
 
 * \retval 1 on success, 0 otherwise
1259
 
 * 
1260
 
 * \section Example
1261
 
 * 
1262
 
 * waittillguiexist ('dlgOpen')
1263
 
 * 
1264
 
 * This function will be useful, when some event is fired and after that if a new window is expected, we can use this function to wait for window to appear.
1265
 
 * 
1266
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1267
 
 */
1268
 
 
1269
 
/**
1270
 
 * \page waittillguinotexist waittillguinotexist
1271
 
 * \section Syntax
1272
 
 * 
1273
 
 * waittillguinotexist ('\<window name\>'[, '\<component name\>'[, guiTimeOut]])
1274
 
 * 
1275
 
 * \section Description
1276
 
 * 
1277
 
 * If the given window name does not exist, this function returns 1. If window exist, then this function returns 0. Difference between \ref guiexist and waitguinotexist is, waitguinotexist waits for maximum 30 seconds. Still the window does not disappear, then 0 is returned. We can set the environment variable 'GUI_TIMEOUT' to change the default waiting time. We can wait for component also and its an optional argument. The default value of guiTimeOut is None and it can be changed either by environment variable or by passing an integer argument > 0. This timeout will be for this specific window and it will not affect the global default time out settings. If you want to change the global default time out settings use guitimeout or objtimeout function appropriately.
1278
 
 * 
1279
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
1280
 
 * 
1281
 
 * \retval 1 on success, 0 otherwise
1282
 
 * 
1283
 
 * \section Example
1284
 
 * 
1285
 
 * waittillguinotexist ('dlgOpen')
1286
 
 * 
1287
 
 * This function will be useful, when some event is fired and after that if an existing window should close, we can use this function to wait till the window closes.
1288
 
 * 
1289
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1290
 
 */
1291
 
 
1292
 
/**
1293
 
 * \page log log
1294
 
 * \section Syntax
1295
 
 * 
1296
 
 * log ('\<Message to be logged\>', '\<tag\>')
1297
 
 * 
1298
 
 * where tag can be any of these
1299
 
 * 
1300
 
 * \subsection debug
1301
 
 * 
1302
 
 * messages can be logged while executing in debug mode
1303
 
 * 
1304
 
 * \subsection warning
1305
 
 * 
1306
 
 * warning message  can be logged
1307
 
 * 
1308
 
 * \subsection teststart
1309
 
 * 
1310
 
 * tag used to indicate the beginning of the test suite
1311
 
 * 
1312
 
 * \subsection testend
1313
 
 * 
1314
 
 * tag used to indicate the end of the test suite
1315
 
 * 
1316
 
 * \subsection begin
1317
 
 * 
1318
 
 * tag used to indicate the beginning of test case
1319
 
 * 
1320
 
 * \subsection end
1321
 
 * 
1322
 
 * tag used at the end of the test case
1323
 
 * 
1324
 
 * \subsection error
1325
 
 * 
1326
 
 * error messages can be logged with this message
1327
 
 * 
1328
 
 * \subsection pass
1329
 
 * 
1330
 
 * message will be logged on successful execution of the testcases
1331
 
 *  
1332
 
 * \subsection fail
1333
 
 * 
1334
 
 * message will be logged on if execution of testcases fail
1335
 
 * 
1336
 
 * \note Messges for the Tags teststart and testend should not contain spaces in between
1337
 
 * 
1338
 
 * begin and end: These keywords are to be used with the same logging message and at beginning and end of testscripts
1339
 
 * 
1340
 
 * teststart and testend: These keywords are to be used with the same logging message and at the beginning and end of testcases
1341
 
 * 
1342
 
 * \section Description
1343
 
 * 
1344
 
 * Logs the message in the log.xml with the tag which can be viewed after the execution of scripts
1345
 
 * 
1346
 
 * \section ImplementationDetails
1347
 
 * 
1348
 
 * The required message will be logged into the log.xml on execution of scripts
1349
 
 * 
1350
 
 * \retval 1 on success and 0 on error
1351
 
 * 
1352
 
 * \section Example
1353
 
 * 
1354
 
 * With Respect to Evolution:
1355
 
 * 
1356
 
 * 1) log ('EvolutionSuite', 'begin')
1357
 
 * 
1358
 
 * execfile ('evolution.py')
1359
 
 * 
1360
 
 * log ('EvolutionSuite', 'end')
1361
 
 * 
1362
 
 * 2) With respect to Appointment-to check the checkbox, 
1363
 
 * 
1364
 
 * In Try Block:
1365
 
 * 
1366
 
 * selecttab('dlgAppointment-NoSummary', 'ptlAppointment-Nosummary', '1')
1367
 
 *       
1368
 
 * log ('Selecttab-In-Appointment', 'pass')
1369
 
 * 
1370
 
 * In except block:
1371
 
 * 
1372
 
 * print "Error"
1373
 
 * 
1374
 
 * log ('Selecttab','fail')
1375
 
 * 
1376
 
 * 3) With respect to creation of vFolders
1377
 
 * 
1378
 
 * log ('Creation-of-vFolders', 'teststart')
1379
 
 * 
1380
 
 * Create_folder()
1381
 
 * 
1382
 
 * log ('Creation-of-vFolders', 'testend')
1383
 
 * 
1384
 
 * 4) Log message showing success of some test case 
1385
 
 * 
1386
 
 * from ldtp import *
1387
 
 * 
1388
 
 * You can log the message to start the test case before writing the test case as
1389
 
 * 
1390
 
 * log ('Open a file', 'teststart')
1391
 
 * 
1392
 
 * log ('opening a file', 'pass')
1393
 
 * 
1394
 
 * \author Nagashree <mnagashree@novell.com>
1395
 
 */
1396
 
 
1397
 
/**
1398
 
 * \page ldtplog ldtplog
1399
 
 * \section Syntax
1400
 
 * 
1401
 
 * ldtplog ('\<Message to be logged\>', '\<tag\>')
1402
 
 * 
1403
 
 * where tag can be any of these
1404
 
 * 
1405
 
 * \subsection debug
1406
 
 * 
1407
 
 * messages can be logged while executing in debug mode
1408
 
 * 
1409
 
 * \subsection warning
1410
 
 * 
1411
 
 * warning message  can be logged
1412
 
 * 
1413
 
 * \subsection teststart
1414
 
 * 
1415
 
 * tag used to indicate the beginning of the test suite
1416
 
 * 
1417
 
 * \subsection testend
1418
 
 * 
1419
 
 * tag used to indicate the end of the test suite
1420
 
 * 
1421
 
 * \subsection begin
1422
 
 * 
1423
 
 * tag used to indicate the beginning of test case
1424
 
 * 
1425
 
 * \subsection end
1426
 
 * 
1427
 
 * tag used at the end of the test case
1428
 
 * 
1429
 
 * \subsection error
1430
 
 * 
1431
 
 * error messages can be logged with this message
1432
 
 * 
1433
 
 * \subsection pass
1434
 
 * 
1435
 
 * message will be logged on successful execution of the testcases
1436
 
 *  
1437
 
 * \subsection fail
1438
 
 * 
1439
 
 * message will be logged on if execution of testcases fail
1440
 
 * 
1441
 
 * \note Messges for the Tags teststart and testend should not contain spaces in between
1442
 
 * 
1443
 
 * begin and end: These keywords are to be used with the same logging message and at beginning and end of testscripts
1444
 
 * 
1445
 
 * teststart and testend: These keywords are to be used with the same logging message and at the beginning and end of testcases
1446
 
 * 
1447
 
 * \section Description
1448
 
 * 
1449
 
 * Logs the message in the specified log file in LDTP engine side, with the tag which can be viewed after the execution of scripts
1450
 
 * 
1451
 
 * \section ImplementationDetails
1452
 
 * 
1453
 
 * The required message will be logged into the log.xml on execution of scripts
1454
 
 * 
1455
 
 * \retval 1 on success and 0 on error
1456
 
 * 
1457
 
 * \section Example
1458
 
 * 
1459
 
 * With Respect to Evolution:
1460
 
 * 
1461
 
 * 1) ldtplog ('EvolutionSuite', 'begin')
1462
 
 * 
1463
 
 * execfile ('evolution.py')
1464
 
 * 
1465
 
 * ldtplog ('EvolutionSuite', 'end')
1466
 
 * 
1467
 
 * 2) With respect to Appointment-to check the checkbox, 
1468
 
 * 
1469
 
 * In Try Block:
1470
 
 * 
1471
 
 * selecttab('dlgAppointment-NoSummary', 'ptlAppointment-Nosummary', '1')
1472
 
 *       
1473
 
 * ldtplog ('Selecttab-In-Appointment', 'pass')
1474
 
 * 
1475
 
 * In except block:
1476
 
 * 
1477
 
 * print "Error"
1478
 
 * 
1479
 
 * ldtplog ('Selecttab','fail')
1480
 
 * 
1481
 
 * 3) With respect to creation of vFolders
1482
 
 * 
1483
 
 * ldtplog ('Creation-of-vFolders', 'teststart')
1484
 
 * 
1485
 
 * Create_folder()
1486
 
 * 
1487
 
 * ldtplog ('Creation-of-vFolders', 'testend')
1488
 
 * 
1489
 
 * 4) Log message showing success of some test case 
1490
 
 * 
1491
 
 * from ldtp import *
1492
 
 * 
1493
 
 * You can log the message to start the test case before writing the test case as
1494
 
 * 
1495
 
 * ldtplog ('Open a file', 'teststart')
1496
 
 * 
1497
 
 * ldtplog ('opening a file', 'pass')
1498
 
 * 
1499
 
 * \author Nagashree <mnagashree@novell.com>
1500
 
 */
1501
 
 
1502
 
/**
1503
 
 * \page reinitldtp reinitldtp
1504
 
 * \section Syntax
1505
 
 * 
1506
 
 * reinitldtp ()
1507
 
 *
1508
 
 * \section Description
1509
 
 * 
1510
 
 * When we work with applications like nautilus, if we open a new window, the new window will not be recognized, until we close and open the session. In case of Mozilla Firefox also we could notice the same behaviour. Like opening Preference window, opening printer dialog etc.
1511
 
 * 
1512
 
 * \section ImplementationDetails
1513
 
 * 
1514
 
 * Closes the existing accessibility connection with at-spi-registryd and opens a new connection.
1515
 
 *
1516
 
 * \retval 1 on success, LdtpExecutionError on failure
1517
 
 * 
1518
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
1519
 
 * 
1520
 
 * \section Example
1521
 
 * 
1522
 
 * reinitldtp ()
1523
 
 * 
1524
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1525
 
 */
1526
 
 
1527
 
/**
1528
 
 * \page check check
1529
 
 * \section Syntax
1530
 
 * 
1531
 
 * check ('\<window name\>', '\<component name\>')
1532
 
 * 
1533
 
 * \section Description
1534
 
 * 
1535
 
 * Check (tick) the check box state.
1536
 
 * 
1537
 
 * \section ImplementationDetails
1538
 
 * 
1539
 
 * \retval 1 if state is checked, else 0.
1540
 
 * 
1541
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/check-box.c
1542
 
 * 
1543
 
 * \section Example
1544
 
 * 
1545
 
 * from ldtp import *
1546
 
 * 
1547
 
 * For check menu item with respect to gedit menu
1548
 
 * 
1549
 
 * check ('gedit', 'mnuOutputWindow')
1550
 
 * 
1551
 
 * For check menu item with respect to gedit menu
1552
 
 * 
1553
 
 * check ('gedit', 'mnuToolbar')
1554
 
 * 
1555
 
 * For check box with respect to gedit preferences
1556
 
 * 
1557
 
 * check ('dlgPreferences', 'cboxEnableAutoIndentation')
1558
 
 * 
1559
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1560
 
 * \author Khasim Shaheed <khasim.shaheed@gmail.com>
1561
 
 */
1562
 
 
1563
 
/** \page uncheck uncheck
1564
 
 * \section Syntax
1565
 
 * 
1566
 
 * uncheck ('\<window name\>', '\<component name\>')
1567
 
 * 
1568
 
 * \section Description
1569
 
 * 
1570
 
 * Uncheck (un-tick) the check  state.
1571
 
 * 
1572
 
 * \section ImplementationDetails
1573
 
 * 
1574
 
 * \retval 1 if state is unchecked, else 0.
1575
 
 * 
1576
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/check-box.c
1577
 
 * 
1578
 
 * \section Example
1579
 
 * 
1580
 
 * from ldtp import *
1581
 
 * 
1582
 
 * To uncheck menu item with respect to gedit menu
1583
 
 * 
1584
 
 * uncheck ('gedit', 'mnuOutputWindow')
1585
 
 * 
1586
 
 * For check menu item with respect to gedit menu
1587
 
 * 
1588
 
 * uncheck ('gedit', 'mnuToolbar')
1589
 
 * 
1590
 
 * To uncheck box with respect to gedit preferences
1591
 
 * 
1592
 
 * uncheck ('dlgPreferences', 'cboxEnableAutoIndentation')
1593
 
 *
1594
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1595
 
 */
1596
 
 
1597
 
/** \page click click
1598
 
 * \section Syntax
1599
 
 * 
1600
 
 * click ('\<window name\>', '\<component name\>')
1601
 
 * 
1602
 
 * \section Description
1603
 
 * 
1604
 
 * click on radio button / check box / push button/ combo box/ radio menu item/ toggle button/ radio button.
1605
 
 * 
1606
 
 * \section ImplementationDetails
1607
 
 * 
1608
 
 * \subsection Radio Radio Button
1609
 
 * 
1610
 
 * If radio button is already in checked state, then this function will uncheck (unset) it.
1611
 
 * 
1612
 
 * If radio button is already in unchecked state, then this function will check (set) it.
1613
 
 * 
1614
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/radio-button.c
1615
 
 * 
1616
 
 * \subsection Check Check Box
1617
 
 * 
1618
 
 * If check box is already in checked state, then this function will uncheck (unset) it.
1619
 
 * 
1620
 
 * If check box is already in unchecked state, then this function will check (set) it.
1621
 
 * 
1622
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/check-box.c
1623
 
 * 
1624
 
 * \subsection Push Push Button
1625
 
 * 
1626
 
 * If push button state is enabled, then click on the object.
1627
 
 * 
1628
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/push-button.c
1629
 
 * 
1630
 
 * \subsection Toggle Toggle Button
1631
 
 * 
1632
 
 * Click on the toggle button.
1633
 
 * 
1634
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/toggle-button.c
1635
 
 * 
1636
 
 * \subsection Combo Combo Box
1637
 
 * 
1638
 
 * Clicks on combo box, drop down list of combo box will be visible if not already else drop down list of combo box closes.
1639
 
 * 
1640
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/combo-box.c
1641
 
 * 
1642
 
 * \section Examples
1643
 
 * 
1644
 
 * Example for push button (With respect to gedit open dialog)
1645
 
 * 
1646
 
 * click ('dlgOpen', 'btnOpen')
1647
 
 * 
1648
 
 * For Check box, Check menu item, on doing this action, the state will be toggled.
1649
 
 * 
1650
 
 * For Radio button, Radio menu item, if they are not already selected, they are selected, otherwise silently ignored.
1651
 
 *
1652
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1653
 
 */
1654
 
 
1655
 
/** \page verifycheck verifycheck
1656
 
 * \section Syntax
1657
 
 * 
1658
 
 * verifycheck ('\<window name\>', '\<component name\>')
1659
 
 * 
1660
 
 * \section Description
1661
 
 * 
1662
 
 * Checks the state of check box
1663
 
 * 
1664
 
 * \retval On check box state is checked returns 1, else 0.
1665
 
 * 
1666
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/check-box.c
1667
 
 * 
1668
 
 * \section Examples
1669
 
 * 
1670
 
 * from ldtp import *
1671
 
 * 
1672
 
 * For check menu item with respect to gedit menu
1673
 
 * 
1674
 
 * verifycheck ('gedit', 'mnuView;mnOutputWindow')
1675
 
 * 
1676
 
 * For check box with respect to gedit preferences
1677
 
 * 
1678
 
 * verifycheck ('dlgPreferences', 'cboxEnableAutoIndentation')
1679
 
 *
1680
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1681
 
 * \author Aishwariya <aishwariyabhavan@yahoo.com>
1682
 
 * \author Khasim Shaheed <khasim.shaheed@gmail.com>
1683
 
 */
1684
 
 
1685
 
/** \page verifyuncheck verifyuncheck
1686
 
 * \section Syntax
1687
 
 * 
1688
 
 * verifyuncheck ('\<window name\>', '\<component name\>')
1689
 
 * 
1690
 
 * \section Description
1691
 
 * 
1692
 
 * Checks the state of check box.
1693
 
 * 
1694
 
 * \retval On check box state is un-checked returns 1, else 0.
1695
 
 * 
1696
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/check-box.c
1697
 
 * 
1698
 
 * \section Examples
1699
 
 * 
1700
 
 * from ldtp import *
1701
 
 * 
1702
 
 * To verify uncheck menu item with respect to gedit menu
1703
 
 * 
1704
 
 * verifyuncheck ('gedit', 'mnuView;mnOutputWindow')
1705
 
 * 
1706
 
 * To verify uncheck box with respect to gedit preferences
1707
 
 * 
1708
 
 * verifyuncheck ('dlgPreferences', 'cboxEnableAutoIndentation')
1709
 
 *
1710
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1711
 
 * \author Khasim Shaheed <khasim.shaheed@gmail.com>
1712
 
 */
1713
 
 
1714
 
/** \page menuitemenabled menuitemenabled
1715
 
 * \section Syntax
1716
 
 * 
1717
 
 * menuitemenabled ('\<window name\>', '\<menu item\>')
1718
 
 *
1719
 
 * \section Description
1720
 
 * 
1721
 
 * Verify whether a menu is enabled or not
1722
 
 * 
1723
 
 * \retval 1 on success, 0 on failure
1724
 
 * 
1725
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/menu-item.c
1726
 
 * 
1727
 
 * \section Example
1728
 
 *
1729
 
 * With respect to gedit, View menu and Toolbar check menuitem, we can verify whether the menu is enabled or not. If enabled 1 will be returned, else 0 will be returned.
1730
 
 *
1731
 
 * menuitemenabled ('*-gedit', 'mnuView;mnuToolbar')
1732
 
 *
1733
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1734
 
 */
1735
 
 
1736
 
/** \page verifymenucheck verifymenucheck
1737
 
 * \section Syntax
1738
 
 * 
1739
 
 * verifymenucheck ('\<window name\>', '\<menu item\>')
1740
 
 *
1741
 
 * \section Description
1742
 
 * 
1743
 
 * Verify whether a menu is checked or not
1744
 
 * 
1745
 
 * \retval 1 on success, 0 on failure
1746
 
 * 
1747
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/check-menu-item.c
1748
 
 * 
1749
 
 * \section Example
1750
 
 *
1751
 
 * With respect to gedit, View menu and Toolbar check menuitem, we can verify whether the menu is checked or not. If checked 1 will be returned, else 0 will be returned.
1752
 
 *
1753
 
 * verifymenucheck ('*-gedit', 'mnuView;mnuToolbar')
1754
 
 *
1755
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1756
 
 */
1757
 
 
1758
 
/** \page verifymenuuncheck verifymenuuncheck
1759
 
 * \section Syntax
1760
 
 * 
1761
 
 * verifymenuuncheck ('\<window name\>', '\<menu item\>')
1762
 
 *
1763
 
 * \section Description
1764
 
 * 
1765
 
 * Verify whether a menu is unchecked or checked
1766
 
 * 
1767
 
 * \retval 1 on success, 0 on failure
1768
 
 * 
1769
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/check-menu-item.c
1770
 
 * 
1771
 
 * \section Example
1772
 
 *
1773
 
 * With respect to gedit, View menu and Toolbar check menuitem, we can verify whether the menu is unchecked or not. If unchecked 1 will be returned, else 0 will be returned.
1774
 
 *
1775
 
 * verifymenuuncheck ('*-gedit', 'mnuView;mnuToolbar')
1776
 
 *
1777
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1778
 
 */
1779
 
 
1780
 
/** \page menucheck menucheck
1781
 
 * \section Syntax
1782
 
 * 
1783
 
 * menucheck ('\<window name\>', '\<menu item\>')
1784
 
 *
1785
 
 * \section Description
1786
 
 * 
1787
 
 * Checks a menu item, if its already checked it will be silently ignored
1788
 
 * 
1789
 
 * \retval 1 on success, LdtpExecutionError exception on failure
1790
 
 * 
1791
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/check-menu-item.c
1792
 
 * 
1793
 
 * \section Example
1794
 
 * 
1795
 
 * With respect to gedit, View menu and Toolbar check menuitem, we can check the menuitem. If its already checked, it will be silently ignored.
1796
 
 *
1797
 
 * menucheck ('*-gedit', 'mnuView;mnuToolbar')
1798
 
 *
1799
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1800
 
 */
1801
 
 
1802
 
/** \page menuuncheck menuuncheck
1803
 
 * \section Syntax
1804
 
 * 
1805
 
 * menuuncheck ('\<window name\>', '\<menu item\>')
1806
 
 *
1807
 
 * \section Description
1808
 
 * 
1809
 
 * Unchecks a menu item, if its already unchecked it will be silently ignored
1810
 
 * 
1811
 
 * \retval 1 on success, LdtpExecutionError exception on failure
1812
 
 * 
1813
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/check-menu-item.c
1814
 
 * 
1815
 
 * \section Example
1816
 
 * 
1817
 
 * With respect to gedit, View menu and Toolbar check menuitem, we can uncheck the menuitem. If its already unchecked, it will be silently ignored.
1818
 
 *
1819
 
 * menuuncheck ('*-gedit', 'mnuView;mnuToolbar')
1820
 
 *
1821
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1822
 
 */
1823
 
 
1824
 
/** \page setcursorposition setcursorposition
1825
 
 * \section Syntax
1826
 
 * 
1827
 
 * setcursorposition ('\<window name\>', '\<text object name\>', \<position\>)
1828
 
 *
1829
 
 * \section Description
1830
 
 * 
1831
 
 * Sets cursor position in a text field
1832
 
 * 
1833
 
 * \retval 1 on success, LdtpExecutionError exception on failure
1834
 
 * 
1835
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
1836
 
 * 
1837
 
 * \section Example
1838
 
 * 
1839
 
 * from ldtp import *
1840
 
 *
1841
 
 * # Assuming that gedit is opened
1842
 
 *
1843
 
 * settextvalue ('*-gedit', 'txt0', 'Testing setcursorposition function of LDTP')
1844
 
 *
1845
 
 * setcursorposition ('*-gedit', 'txt0', 9)
1846
 
 *
1847
 
 * The above example will set the given text value in first tab of gedit window and the cursor position will be moved to column number 10 of the first row.
1848
 
 *
1849
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1850
 
 */
1851
 
 
1852
 
/** \page istextstateenabled istextstateenabled
1853
 
 * \section Syntax
1854
 
 * 
1855
 
 * istextstateenabled ('\<window name\>', '\<text object name\>')
1856
 
 *
1857
 
 * \section Description
1858
 
 * 
1859
 
 * Checks whether the text object is in editable state or not.
1860
 
 * 
1861
 
 * \retval 1 on success, 0 on failure.
1862
 
 * 
1863
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
1864
 
 * 
1865
 
 * \section Example
1866
 
 * 
1867
 
 * \todo
1868
 
 *
1869
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1870
 
 */
1871
 
 
1872
 
/** \page getstatusbartext getstatusbartext
1873
 
 * \section Syntax
1874
 
 * 
1875
 
 * getstatusbartext ('\<window name\>', '\<status bar name\>')
1876
 
 *
1877
 
 * \section Description
1878
 
 * 
1879
 
 * Gets the text displayed in the status bar
1880
 
 * 
1881
 
 * \retval text content displayed in the status bar on success, LdtpExecutionError exception on failure.
1882
 
 * 
1883
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/status-bar.c
1884
 
 * 
1885
 
 * \section Example
1886
 
 * 
1887
 
 * \todo
1888
 
 *
1889
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1890
 
 */
1891
 
 
1892
 
/** \page verifystatusbar verifystatusbar
1893
 
 * \section Syntax
1894
 
 * 
1895
 
 * verifystatusbar ('\<window name\>', '\<status bar name\>')
1896
 
 *
1897
 
 * \section Description
1898
 
 * 
1899
 
 * Checks whether the object is status bar or not
1900
 
 * 
1901
 
 * \retval 1 on success, 0 on failure
1902
 
 * 
1903
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/status-bar.c
1904
 
 * 
1905
 
 * \section Example
1906
 
 * 
1907
 
 * With respect to gedit status bar text
1908
 
 *
1909
 
 * from ldtp import *
1910
 
 *
1911
 
 * verifystatusbar ('*-gedit', 'stat0')
1912
 
 *
1913
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1914
 
 */
1915
 
 
1916
 
/** \page verifystatusbarvisible verifystatusbarvisible
1917
 
 * \section Syntax
1918
 
 * 
1919
 
 * verifystatusbarvisible ('\<window name\>', '\<status bar name\>')
1920
 
 *
1921
 
 * \section Description
1922
 
 * 
1923
 
 * Checks whether the status bar object is visible or not
1924
 
 * 
1925
 
 * \retval 1 on success, 0 on failure
1926
 
 * 
1927
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/status-bar.c
1928
 
 * 
1929
 
 * \section Example
1930
 
 * 
1931
 
 * With respect to gedit status bar text
1932
 
 *
1933
 
 * from ldtp import *
1934
 
 *
1935
 
 * verifystatusbarvisible ('*-gedit', 'stat0')
1936
 
 *
1937
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1938
 
 */
1939
 
 
1940
 
/** \page selecttextbyindexandregion selecttextbyindexandregion
1941
 
 * \section Syntax
1942
 
 * 
1943
 
 * selecttextbyindexandregion ('\<window name\>', '\<text object name\>'[, <start position\>[, <end position\>[, <selection number\>]]])
1944
 
 *
1945
 
 * \section Description
1946
 
 * 
1947
 
 * Select text by index (text selection change based on index) and the region (start and end position)
1948
 
 *
1949
 
 * Reference: http://developer.gnome.org/doc/API/2.0/at-spi/at-spi-cspi-AccessibleText-Interface.html#AccessibleText-setSelection
1950
 
 * 
1951
 
 * \retval 1 on success, LdtpExecutionError exception on failure
1952
 
 * 
1953
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
1954
 
 * 
1955
 
 * \section Example
1956
 
 * 
1957
 
 * \todo
1958
 
 *
1959
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1960
 
 */
1961
 
 
1962
 
/** \page selecttextbyname selecttextbyname
1963
 
 * \section Syntax
1964
 
 * 
1965
 
 * selecttextbyname ('\<window name\>', '\<text object name\>')
1966
 
 *
1967
 
 * \section Description
1968
 
 * 
1969
 
 * Select text by name
1970
 
 *
1971
 
 * \retval 1 on success, LdtpExecutionError exception on failure
1972
 
 * 
1973
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
1974
 
 * 
1975
 
 * \section Example
1976
 
 * 
1977
 
 * \todo
1978
 
 *
1979
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
1980
 
 */
1981
 
 
1982
 
/** \page getcursorposition getcursorposition
1983
 
 * \section Syntax
1984
 
 * 
1985
 
 * getcursorposition ('\<window name\>', '\<text object name\>')
1986
 
 *
1987
 
 * \section Description
1988
 
 * 
1989
 
 * Gets the current cursor position of the given text object
1990
 
 * 
1991
 
 * \retval cursor position which is of type long on success, LdtpExecutionError exception on failure
1992
 
 * 
1993
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
1994
 
 * 
1995
 
 * \section Example
1996
 
 *
1997
 
 * from ldtp import *
1998
 
 *
1999
 
 * # Assuming that gedit is opened
2000
 
 *
2001
 
 * settextvalue ('*-gedit', 'txt0', 'Testing setcursorposition function of LDTP')
2002
 
 *
2003
 
 * getcursorposition ('*-gedit', 'txt0')
2004
 
 *
2005
 
 * The above example will get the current cursor position in the text object of gedit windows first tab.
2006
 
 *
2007
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2008
 
 */
2009
 
 
2010
 
/** \page hidelist hidelist
2011
 
 * \section Syntax
2012
 
 * 
2013
 
 * hidelist ('\<dlgName\>', '\<cmbName\>')
2014
 
 *
2015
 
 * \section Description
2016
 
 * 
2017
 
 * Hides combo box drop down list in the current dialog. Suppose in previous operation one testcase has clicked on combo box, its drop down list will be displayed. If further no any operation has been done on that combo box then to close that drop down list 'HideList' action is required
2018
 
 * 
2019
 
 * \section ImplementationDetails
2020
 
 * 
2021
 
 * Combo box will generally have a list as its child or a menu as its child. So this function gets object handle of list object, checks if list of combo box is visible, if yes then just click on combo box, click operation will close drop down list of combo box.
2022
 
 *
2023
 
 * \retval 1 on success, LdtpExecutionError exception on failure
2024
 
 * 
2025
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/combo-box.c
2026
 
 * 
2027
 
 * \section Example
2028
 
 * 
2029
 
 * \todo
2030
 
 *
2031
 
 * \author Poornima <pnayak@novell.com>
2032
 
 */
2033
 
 
2034
 
/** \page comboselect comboselect
2035
 
 * \section Syntax
2036
 
 *
2037
 
 * comboselect ('\<window name\>', '\<component name\>', '\<menu item name\>')
2038
 
 *
2039
 
 * comboselect ('\<window name\>', '\<component name\>', '\<list item name\>')
2040
 
 *
2041
 
 * \section Description
2042
 
 *
2043
 
 * Select a menu item or list item in a combo box based on name
2044
 
 *
2045
 
 * \retval 1 on success, LdtpExecutionError exception on failure
2046
 
 *
2047
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/combo-box.c
2048
 
 *
2049
 
 * \section Example
2050
 
 *
2051
 
 * In gnome-search-tool combo box 'Available options' to select the menu item 'Contains the text'
2052
 
 * 
2053
 
 * comboselect ('SearchForFiles', 'cmbAvailableoptions', 'Contains the text')
2054
 
 * 
2055
 
 * \author Poornima <pnayak@novell.com>
2056
 
 */
2057
 
 
2058
 
/** \page selectindex selectindex
2059
 
 * \section Syntax
2060
 
 *
2061
 
 * selectindex ('\<dlgName\>', '\<object name\>', \<index\>)
2062
 
 *
2063
 
 * \section Description
2064
 
 *
2065
 
 * SelectIndex action will select an item from combo box where value of index is pointing to its position in list/menu.
2066
 
 *
2067
 
 * \section ImplementationDetails
2068
 
 *
2069
 
 * Combo box will generally have a list as its child or a menu as its
2070
 
 * child. SelectIndex function will try to find whether child type is
2071
 
 * menu or list, if child type is list then there will be a text box
2072
 
 * associated with combo box. When child type is list, selects item at
2073
 
 * index value from list box and sets that value to the text box
2074
 
 * associated with combo box. If child type is menu, value specified
2075
 
 * in tha argument will be index of menu item, corressponding menu
2076
 
 * item will be selected.
2077
 
 * 
2078
 
 * In layered pane, this function call selects the object based on index.
2079
 
 *
2080
 
 * \retval 1 on success, LdtpExecutionError exception on failure
2081
 
 *
2082
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/combo-box.c
2083
 
 *
2084
 
 * \section Example
2085
 
 *
2086
 
 * # Selects the first folder / file in desktop
2087
 
 * 
2088
 
 * selectindex ('x-nautilus-desktop', 'Icon View', 0)
2089
 
 *
2090
 
 * \author Poornima <pnayak@novell.com>
2091
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2092
 
 */
2093
 
 
2094
 
/** \page unselectindex unselectindex
2095
 
 * \section Syntax
2096
 
 *
2097
 
 * unselectindex ('\<dlgName\>', '\<object name\>', \<index\>)
2098
 
 *
2099
 
 * \section Description
2100
 
 *
2101
 
 * In layered pane, this function call unselects the object based on index.
2102
 
 *
2103
 
 * \retval 1 on success, LdtpExecutionError exception on failure
2104
 
 *
2105
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/layered-pane.c
2106
 
 *
2107
 
 * \section Example
2108
 
 *
2109
 
 * # Unselects the first folder / file in desktop
2110
 
 * 
2111
 
 * unselectindex ('x-nautilus-desktop', 'Icon View', 0)
2112
 
 *
2113
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2114
 
 */
2115
 
 
2116
 
/** \page unselectitemindex unselectitemindex
2117
 
 * \section Syntax
2118
 
 *
2119
 
 * unselectitemindex ('\<dlgName\>', '\<object name\>', \<index\>)
2120
 
 *
2121
 
 * \section Description
2122
 
 *
2123
 
 * In layered pane, this function call unselects the object based on
2124
 
 * the currently selected item index.
2125
 
 *
2126
 
 * \retval 1 on success, LdtpExecutionError exception on failure
2127
 
 *
2128
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/layered-pane.c
2129
 
 *
2130
 
 * \section Example
2131
 
 *
2132
 
 * # Unselects the first folder / file in desktop that is already selected
2133
 
 * 
2134
 
 * unselectitemindex ('x-nautilus-desktop', 'Icon View', 0)
2135
 
 *
2136
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2137
 
 */
2138
 
 
2139
 
/** \page selectall selectall
2140
 
 * \section Syntax
2141
 
 *
2142
 
 * selectall ('\<dlgName\>', '\<object name\>')
2143
 
 *
2144
 
 * \section Description
2145
 
 *
2146
 
 * In layered pane, this function call selects all the object.
2147
 
 *
2148
 
 * \retval 1 on success, LdtpExecutionError exception on failure
2149
 
 *
2150
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/layered-pane.c
2151
 
 *
2152
 
 * \section Example
2153
 
 *
2154
 
 * selectall ('x-nautilus-desktop', 'Icon View')
2155
 
 *
2156
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2157
 
 */
2158
 
 
2159
 
/** \page unselectall unselectall
2160
 
 * \section Syntax
2161
 
 *
2162
 
 * unselectall ('\<dlgName\>', '\<object name\>')
2163
 
 *
2164
 
 * \section Description
2165
 
 *
2166
 
 * In layered pane, this function call unselects all the object.
2167
 
 *
2168
 
 * \retval 1 on success, LdtpExecutionError exception on failure
2169
 
 *
2170
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/layered-pane.c
2171
 
 *
2172
 
 * \section Example
2173
 
 *
2174
 
 * unselectall ('x-nautilus-desktop', 'Icon View')
2175
 
 *
2176
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2177
 
 */
2178
 
 
2179
 
/** \page selecteditemcount selecteditemcount
2180
 
 * \section Syntax
2181
 
 *
2182
 
 * selecteditemcount ('\<dlgName\>', '\<object name\>')
2183
 
 *
2184
 
 * \section Description
2185
 
 *
2186
 
 * In layered pane, this function call returns the selected item count.
2187
 
 *
2188
 
 * \retval Selected item count on success, LdtpExecutionError exception on failure
2189
 
 *
2190
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/layered-pane.c
2191
 
 *
2192
 
 * \section Example
2193
 
 *
2194
 
 * selecteditemcount ('x-nautilus-desktop', 'Icon View')
2195
 
 *
2196
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2197
 
 */
2198
 
 
2199
 
/** \page ischildselected ischildselected
2200
 
 * \section Syntax
2201
 
 *
2202
 
 * ischildselected ('\<dlgName\>', '\<object name\>', '\<item\>')
2203
 
 *
2204
 
 * \section Description
2205
 
 *
2206
 
 * In layered pane, this function call checks whether the given file /
2207
 
 * folder is selected or not.
2208
 
 *
2209
 
 * \retval Selected item count on success, LdtpExecutionError exception on failure
2210
 
 *
2211
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/layered-pane.c
2212
 
 *
2213
 
 * \section Example
2214
 
 *
2215
 
 * ischildselected ('x-nautilus-desktop', 'Icon View', 'file-name.txt')
2216
 
 *
2217
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2218
 
 */
2219
 
 
2220
 
/** \page ischilditemselected ischilditemselected
2221
 
 * \section Syntax
2222
 
 *
2223
 
 * ischilditemselected ('\<dlgName\>', '\<object name\>', '\<item\>')
2224
 
 *
2225
 
 * \section Description
2226
 
 *
2227
 
 * In layered pane, this function call checks whether the given file /
2228
 
 * folder is selected in the previously selected list.
2229
 
 *
2230
 
 * \retval Selected item count on success, LdtpExecutionError exception on failure
2231
 
 *
2232
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/layered-pane.c
2233
 
 *
2234
 
 * \section Example
2235
 
 *
2236
 
 * ischilditemselected ('x-nautilus-desktop', 'Icon View', 'file-name.txt')
2237
 
 *
2238
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2239
 
 */
2240
 
 
2241
 
/** \page ischildindexselected ischildindexselected
2242
 
 * \section Syntax
2243
 
 *
2244
 
 * ischildindexselected ('\<dlgName\>', '\<object name\>', \<index\>)
2245
 
 *
2246
 
 * \section Description
2247
 
 *
2248
 
 * In layered pane, this function call checks whether the given index
2249
 
 * is selected or not.
2250
 
 *
2251
 
 * \retval Selected item count on success, LdtpExecutionError exception on failure
2252
 
 *
2253
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/layered-pane.c
2254
 
 *
2255
 
 * \section Example
2256
 
 *
2257
 
 * ischildindexselected ('x-nautilus-desktop', 'Icon View', 0)
2258
 
 *
2259
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2260
 
 */
2261
 
 
2262
 
/** \page ischilditemindexselected ischilditemindexselected
2263
 
 * \section Syntax
2264
 
 *
2265
 
 * ischilditemindexselected ('\<dlgName\>', '\<object name\>', \<index\>)
2266
 
 *
2267
 
 * \section Description
2268
 
 *
2269
 
 * In layered pane, this function call checks whether the given index
2270
 
 * is selected in the previously selected item.
2271
 
 *
2272
 
 * \retval Selected item count on success, LdtpExecutionError exception on failure
2273
 
 *
2274
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/layered-pane.c
2275
 
 *
2276
 
 * \section Example
2277
 
 *
2278
 
 * ischilditemindexselected ('x-nautilus-desktop', 'Icon View', 0)
2279
 
 *
2280
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2281
 
 */
2282
 
 
2283
 
/** \page settextvalue settextvalue
2284
 
 * \section Syntax
2285
 
 *
2286
 
 * settextvalue ('\<window name\>', '\<component name\>', '\<text\>')
2287
 
 *
2288
 
 * \section Description
2289
 
 *
2290
 
 * puts the text into the component given by the component name
2291
 
 *
2292
 
 * \section ImplementationDetails
2293
 
 *
2294
 
 * In text.c
2295
 
 *
2296
 
 * \retval 1 on success and 0 otherwise
2297
 
 *
2298
 
 * In combo-box.c
2299
 
 *
2300
 
 * Combo box will be associated with child of type 'Text' when one of its child is 'List'. This action gets object handle of 'Text' object associated with combo box and then sets value given in argument in that text box 
2301
 
 *
2302
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c http://cgit.freedesktop.org/ldtp/ldtp/tree/src/combo-box.c
2303
 
 *
2304
 
 * \section Example
2305
 
 *
2306
 
 * With respect to gnome search tool text field
2307
 
 * 
2308
 
 * settextvalue ('SearchforFiles', 'txtNameContainsEntry', 'abcd')
2309
 
 * 
2310
 
 * This is to insert the text 'abcd' into the 'txtNameContainsEntry' field.
2311
 
 * 
2312
 
 * In combo box:
2313
 
 * 
2314
 
 * \todo settextvalue ('\<dlgName\>', '\<cmbName\>', '\<argument\>') 
2315
 
 *
2316
 
 * \author Poornima <pnayak@novell.com>
2317
 
 */
2318
 
 
2319
 
/** \page appendtext appendtext 
2320
 
 * \section Syntax
2321
 
 *
2322
 
 * appendtext ('\<window name\>', '\<component name\>', '\<text\>')
2323
 
 *
2324
 
 * \section Description
2325
 
 *
2326
 
 * Appends the given text with already present text
2327
 
 *
2328
 
 * \section ImplementationDetails
2329
 
 *
2330
 
 * \retval 1 on success and 0 otherwise
2331
 
 *
2332
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
2333
 
 *
2334
 
 * \section Example
2335
 
 *
2336
 
 * With respect to gedit structure
2337
 
 * 
2338
 
 * appendtext('gedit','txtmain','Sample text')
2339
 
 * 
2340
 
 * This to append 'Sample text' to the 'main' text box contents in gedit 
2341
 
 *
2342
 
 * \author Shagan <shagan.glare@gmail.com>
2343
 
 */
2344
 
 
2345
 
/** \page activatetext activatetext
2346
 
 * \section Syntax
2347
 
 *
2348
 
 * activatetext ('\<window name\>', '\<component name\>')
2349
 
 *
2350
 
 * \section Description
2351
 
 *
2352
 
 * activates the text box ( similar to press enter after setting text)
2353
 
 *
2354
 
 * \section ImplementationDetails
2355
 
 *
2356
 
 * \retval 1 on success and 0 otherwise
2357
 
 *
2358
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
2359
 
 *
2360
 
 * \section Example
2361
 
 *
2362
 
 * With respect to gftp-gtk structure
2363
 
 * 
2364
 
 * activatetext ('gFTP', 'txtUser')
2365
 
 * 
2366
 
 * This is to activate the text box 'txtUser' in gftp-gtk 
2367
 
 *
2368
 
 * \author Shagan <shagan.glare@gmail.com>
2369
 
 */
2370
 
 
2371
 
/** \page getcharcount getcharcount
2372
 
 * \section Syntax
2373
 
 *
2374
 
 * getcharcount ('\<window name\>', '\<component name\>')
2375
 
 *
2376
 
 * \section Description
2377
 
 *
2378
 
 * Return the number of characters present in the component identified by the \<component name\>.
2379
 
 *
2380
 
 * \section ImplementationDetails
2381
 
 *
2382
 
 * \retval number of characters
2383
 
 *
2384
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
2385
 
 *
2386
 
 * \section Example
2387
 
 *
2388
 
 * With respect to gedit
2389
 
 * 
2390
 
 * getcharcount ('gedit', 'txt0')
2391
 
 * 
2392
 
 * This will return the number of characters in the file presently open. 
2393
 
 *
2394
 
 * \author Premkumar J <prem.jothimani@gmail.com>
2395
 
 */
2396
 
 
2397
 
/** \page cuttext cuttext
2398
 
 * \section Syntax
2399
 
 *
2400
 
 * cuttext ('\<window name\>', '\<component name\>', \<startindex\>, \<endindex\>)
2401
 
 *
2402
 
 * \section Description
2403
 
 *
2404
 
 * Cut the text from startindex till the endindex in the component given by the component name
2405
 
 *
2406
 
 * \section ImplementationDetails
2407
 
 *
2408
 
 * \retval 1 on success and 0 otherwise
2409
 
 *
2410
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
2411
 
 *
2412
 
 * \section Example
2413
 
 *
2414
 
 * With respect to gedit tool structure
2415
 
 * 
2416
 
 * cuttext ('gedit', 'txtName', 1, 3)
2417
 
 * 
2418
 
 * This is to cut the text from the startindex position till the endindex in the 'txtName' field.
2419
 
 *
2420
 
 * \author Kamakshi <poorvakrishna@yahoo.com>
2421
 
 */
2422
 
 
2423
 
/** \page  copytext copytext
2424
 
 * \section Syntax
2425
 
 *
2426
 
 * copytext ('\<window name\>', '\<component name\>', \<startoffset\>, \<endoffset\>)
2427
 
 *
2428
 
 * \section Description
2429
 
 *
2430
 
 * Copies text within specified offset present in the specified \<component\> into clipboard
2431
 
 *
2432
 
 * \section ImplementationDetails
2433
 
 *
2434
 
 * \retval 1 on success and 0 otherwise
2435
 
 *
2436
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
2437
 
 *
2438
 
 * \section Example
2439
 
 *
2440
 
 * With respect to gedit tool structure
2441
 
 * 
2442
 
 * copytext ('gedit', 'txt0', 5,10)
2443
 
 * 
2444
 
 * This is to copy the text within the offset specified from the 'txt0' field into clipboard. 
2445
 
 *
2446
 
 * \author Premkumar J <prem.jothimani@gmail.com>
2447
 
 */
2448
 
 
2449
 
/** \page inserttext inserttext
2450
 
 * \section Syntax
2451
 
 *
2452
 
 * inserttext ('\<window name\>', '\<component name\>', \<position\>, '\<text\>')
2453
 
 *
2454
 
 * \section Description
2455
 
 *
2456
 
 * Insert the text in the specified position in the component given by the component name
2457
 
 *
2458
 
 * \section ImplementationDetails
2459
 
 *
2460
 
 * \retval 1 on success and 0 otherwise
2461
 
 *
2462
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
2463
 
 *
2464
 
 * \section Example
2465
 
 *
2466
 
 * With respect to gedit
2467
 
 * 
2468
 
 * inserttext ('*-gedit', 'txt0', 5, 'sample text')
2469
 
 * 
2470
 
 * This is to insert the given text at the specified position in the 'txtName' field. 
2471
 
 *
2472
 
 * \author Premkumar J <prem.jothimani@gmail.com>
2473
 
 */
2474
 
 
2475
 
/** \page pastetext pastetext
2476
 
 * \section Syntax
2477
 
 *
2478
 
 * pastetext ('\<window name\>', '\<component name\>', \<position\>)
2479
 
 *
2480
 
 * \section Description
2481
 
 *
2482
 
 * paste the text from the position specified in the component given by the component name
2483
 
 *
2484
 
 * \section ImplementationDetails
2485
 
 *
2486
 
 * \retval 1 on success and 0 otherwise
2487
 
 *
2488
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
2489
 
 *
2490
 
 * \section Example
2491
 
 *
2492
 
 * With respect to gedit tool structure
2493
 
 * 
2494
 
 * pastetext ('gedit', 'txtName', 1)
2495
 
 * 
2496
 
 * This is to paste the text from the position specified in the 'txtName' field. 
2497
 
 *
2498
 
 * \author Kamakshi <poorvakrishna@yahoo.com>
2499
 
 */
2500
 
 
2501
 
/** \page deletetext deletetext
2502
 
 * \section Syntax
2503
 
 *
2504
 
 * deletetext ('\<window name\>', '\<component name\>', \<startindex\>, \<endindex\>)
2505
 
 *
2506
 
 * \section Description
2507
 
 *
2508
 
 * delete the text from the startindex till the endindex in the component given by the component name
2509
 
 *
2510
 
 * \section ImplementationDetails
2511
 
 *
2512
 
 * \retval 1 on success and 0 otherwise
2513
 
 *
2514
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
2515
 
 *
2516
 
 * \section Example
2517
 
 *
2518
 
 * With respect to gedit tool structure
2519
 
 * 
2520
 
 * deletetext ('gedit', 'txtName', 1, 3)
2521
 
 * 
2522
 
 * This is to delete the text from the startindex to endindex specified in the 'txtName'field. 
2523
 
 *
2524
 
 * \author Kamakshi <poorvakrishna@yahoo.com>
2525
 
 */
2526
 
 
2527
 
/** \page showlist showlist
2528
 
 * \section Syntax
2529
 
 *
2530
 
 * showlist ('\<dlgName\>', '\<cmbName\>')
2531
 
 *
2532
 
 * \section Description
2533
 
 *
2534
 
 * Displays combo box drop down list in the current dialog.
2535
 
 *
2536
 
 * \section ImplementationDetails
2537
 
 *
2538
 
 * Combo box will generally have a list as its child or a menu as its child. So this function gets object handle of list object, checks if list of combo box is visible, if not then just click on combo box, click operation will display drop down list of combo box. 
2539
 
 *
2540
 
 * \retval 1 on success, LdtpExecutionError on failure
2541
 
 *
2542
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/combo-box.c
2543
 
 *
2544
 
 * \section Example
2545
 
 *
2546
 
 * \todo
2547
 
 *
2548
 
 * \author Poornima <pnayak@novell.com>
2549
 
 */
2550
 
 
2551
 
/** \page verifydropdown verifydropdown
2552
 
 * \section Syntax
2553
 
 *
2554
 
 * verifydropdown ('\<window name\>', '\<combo box / list name\>')
2555
 
 *
2556
 
 * \section Description
2557
 
 *
2558
 
 * \retval 1 on success, 0 on failure
2559
 
 *
2560
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/combo-box.c
2561
 
 *
2562
 
 * \section Example
2563
 
 *
2564
 
 * \todo
2565
 
 *
2566
 
 * \author Poornima <pnayak@novell.com>
2567
 
 */
2568
 
 
2569
 
/** \page verifyhidelist verifyhidelist
2570
 
 * \section Syntax
2571
 
 *
2572
 
 * verfyhidelist ('\<dlgName\>', '\<cmbName\>')
2573
 
 *
2574
 
 * \section Description
2575
 
 *
2576
 
 * Verifies if combo box drop down list in the current dialog is not visible.
2577
 
 *
2578
 
 * \section ImplementationDetails
2579
 
 *
2580
 
 * Combo box will generally have a list as its child or a menu as its child. So this function gets object handle of list or menu object, checks if list or menu items of combo box is visible, if yes then return minus one else returns zero.
2581
 
 *
2582
 
 * \retval 1 on success, 0 on failure
2583
 
 *
2584
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/combo-box.c
2585
 
 *
2586
 
 * \section Example
2587
 
 *
2588
 
 * \todo
2589
 
 *
2590
 
 * \author Poornima <pnayak@novell.com>
2591
 
 */
2592
 
 
2593
 
/** \page verifyshowlist verifyshowlist
2594
 
 * \section Syntax
2595
 
 *
2596
 
 * verifyshowlist ('\<dlgName\>', '\<cmbName\>')
2597
 
 *
2598
 
 * \section Description
2599
 
 *
2600
 
 * Verifies if combo box drop down list in the current dialog is visible.
2601
 
 *
2602
 
 * \section ImplementationDetails
2603
 
 *
2604
 
 * Combo box will generally have a list as its child or a menu as its child. So this function gets object handle of list or menu object, checks if list or menu items of combo box is visible, if yes then return zero else minus one.
2605
 
 *
2606
 
 * \retval 1 on success, 0 on failure
2607
 
 *
2608
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/combo-box.c
2609
 
 *
2610
 
 * \section Example
2611
 
 *
2612
 
 * \todo
2613
 
 *
2614
 
 * \author Poornima <pnayak@novell.com>
2615
 
 */
2616
 
 
2617
 
/** \page verifyselect verifyselect
2618
 
 * \section Syntax
2619
 
 *
2620
 
 * verifyselect ('\<dlgName\>', '\<cmbName\>', '\<argument\>')
2621
 
 *
2622
 
 * \section Description
2623
 
 *
2624
 
 * VerfySelect action will verify if combo box is set to value given in argument.
2625
 
 *
2626
 
 * \section ImplementationDetails
2627
 
 *
2628
 
 * VerifySelect function will try to find if text box associated with combo box is set to value specified in the argument.
2629
 
 *
2630
 
 * \retval 1 on success, 0 on failure
2631
 
 *
2632
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/combo-box.c
2633
 
 *
2634
 
 * \section Example
2635
 
 *
2636
 
 * In gnome-search-tool combo box 'Available options' to select the menu item 'Contains the text'
2637
 
 * 
2638
 
 * verifyselect ('SearchForFiles', 'cmbAvailableoptions', 'Contains the text')
2639
 
 *
2640
 
 * \author Poornima <pnayak@novell.com>
2641
 
 */
2642
 
 
2643
 
/** \page verifysettext verifysettext
2644
 
 * \section Syntax
2645
 
 *
2646
 
 * verifysettext ('\<window name\>', '\<component name\>', '\<text\>')
2647
 
 *
2648
 
 * \section Description
2649
 
 *
2650
 
 * checks if the text is inserted into the component given by the component name
2651
 
 *
2652
 
 * \section ImplementationDetails
2653
 
 *
2654
 
 * \retval 1 if the text is inserted into the specified component else returns 0
2655
 
 *
2656
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/combo-box.c
2657
 
 *
2658
 
 * \section Example
2659
 
 *
2660
 
 * With respect to gnome search tool structure
2661
 
 * 
2662
 
 * verifysettext ('SearchforFiles', 'txtNameContainsEntry', 'abcd')
2663
 
 * 
2664
 
 * This is to verify if the previous settextvalue function has inserted 'abcd' into the txtNameContainsEntry field in the gnome search tool 
2665
 
 *
2666
 
 * \author Poornima <pnayak@novell.com>
2667
 
 */
2668
 
 
2669
 
/** \page rightclick rightclick
2670
 
 * \section Syntax
2671
 
 *
2672
 
 * rightclick ('\<window name\>', '\<component name\>', '\<menu item\>', '[data]')
2673
 
 *
2674
 
 * \todo icon - rightclick ('\<window name\>', '\<component name\>')
2675
 
 *
2676
 
 * \section Description
2677
 
 *
2678
 
 * Right click on the given object.
2679
 
 *
2680
 
 * \section ImplementationDetails
2681
 
 *
2682
 
 * This function gets the coordinate of the given object and the right click event is generated.
2683
 
 *
2684
 
 * \note If the object's window is not in focus, then this function will fail
2685
 
 *
2686
 
 * \retval 1 on success, LdtpExecutionError exception on failure
2687
 
 *
2688
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
2689
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/layered-pane.c
2690
 
 *
2691
 
 * \section Example
2692
 
 *
2693
 
 * # Right click on an embedded component object type
2694
 
 *
2695
 
 * rightclick ('frmBottomExpandedEdgePanel', 'Volume Control', None)
2696
 
 *
2697
 
 * \author Thanikachalam S <thanika1999@yahoo.com>
2698
 
 * \author Poornima <pnayak@novell.com>
2699
 
 * \author Premkumar J <prem.jothimani@gmail.com>
2700
 
 */
2701
 
 
2702
 
/** \page getlabel getlabel
2703
 
 * \section Syntax
2704
 
 *
2705
 
 * getlabel ('\<window name\>', '\<label name\>')
2706
 
 *
2707
 
 * \section Description
2708
 
 *
2709
 
 * \retval label string on success, LdtpExecutionError exception on failure
2710
 
 *
2711
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/label.c
2712
 
 *
2713
 
 * \section Example
2714
 
 *
2715
 
 * \todo
2716
 
 *
2717
 
 * \author Thanikachalam S <thanika1999@yahoo.com>
2718
 
 */
2719
 
 
2720
 
/** \page getlabelatindex getlabelatindex
2721
 
 * \section Syntax
2722
 
 *
2723
 
 * getlabelatindex ('\<window name\>', '\<panel name\>', index)
2724
 
 *
2725
 
 * \section Description
2726
 
 *
2727
 
 * Gets label name based on index from the panel.
2728
 
 *
2729
 
 * \retval label name on success, LdtpExecutionError exception on failure
2730
 
 *
2731
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/label.c
2732
 
 *
2733
 
 * \section Example
2734
 
 *
2735
 
 * \todo
2736
 
 *
2737
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2738
 
 */
2739
 
 
2740
 
/** \page selectitem selectitem
2741
 
 * \section Syntax
2742
 
 *
2743
 
 * selectitem ('\<window name\>', '\<object name\>', '\<item\>')
2744
 
 *
2745
 
 * \section Description
2746
 
 *
2747
 
 * \retval 1 on success, LdtpExecutionError exception on failure
2748
 
 *
2749
 
 * Refer:
2750
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/layered-pane.c
2751
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/combo-box.c
2752
 
 *
2753
 
 * \section Example
2754
 
 *
2755
 
 * selectitem ('x-nautilus-desktop', 'Icon View', 'file-name.txt')
2756
 
 *
2757
 
 * \author Thanikachalam S <thanika1999@yahoo.com>
2758
 
 */
2759
 
 
2760
 
/** \page unselectitem unselectitem
2761
 
 * \section Syntax
2762
 
 *
2763
 
 * unselectitem ('\<window name\>', '\<object name\>', '\<item\>')
2764
 
 *
2765
 
 * \section Description
2766
 
 *
2767
 
 * Unselect the item that is already selected based on given name
2768
 
 * 
2769
 
 * \retval 1 on success, LdtpExecutionError exception on failure
2770
 
 *
2771
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/layered-pane.c
2772
 
 *
2773
 
 * \section Example
2774
 
 *
2775
 
 * unselectitem ('x-nautilus-desktop', 'Icon View', 'file-name.txt')
2776
 
 *
2777
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2778
 
 */
2779
 
 
2780
 
/** \page selecttextitem selecttextitem
2781
 
 * \section Syntax
2782
 
 *
2783
 
 * selecttextitem ('\<window name\>', '\<combo box name\>', '\<item\>')
2784
 
 *
2785
 
 * \section Description
2786
 
 *
2787
 
 * Selects a text item in a combox box and the combo box may contain either list or menu item.
2788
 
 *
2789
 
 * \retval 1 on success, LdtpExecutionError exception on failure
2790
 
 *
2791
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/combo-box.c
2792
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/list.c
2793
 
 *
2794
 
 * \section Example
2795
 
 *
2796
 
 * With respect to gedit, find dialog
2797
 
 *
2798
 
 * from ldtp import *
2799
 
 *
2800
 
 * click ('*-gedit', 'btnFind')
2801
 
 *
2802
 
 * # assuming that LDTP string is available in the list of searched strings
2803
 
 *
2804
 
 * selecttextitem ('dlgFind', 'cboSearchFor', 'LDTP')
2805
 
 *
2806
 
 * \author Poornima Nayak <pnayak@novell.com>
2807
 
 */
2808
 
 
2809
 
/** \page selectmenuitem selectmenuitem
2810
 
 * \section Syntax
2811
 
 *
2812
 
 * selectmenuitem ('\<window name\>', '\<menu hierarchy\>')
2813
 
 *
2814
 
 * \section Description
2815
 
 *
2816
 
 * Selects the menu item specified.
2817
 
 *
2818
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/menu.c
2819
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/check-menu-item.c
2820
 
 *
2821
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/menu-item.c
2822
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/radio-menu-item.c
2823
 
 *
2824
 
 * \section Example
2825
 
 *
2826
 
 * With respect to gedit menu structure
2827
 
 * 
2828
 
 * selectmenuitem ('*-gedit', 'mnuFile;mnuNew') 
2829
 
 *
2830
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2831
 
 * \author Thanikachalam S <thanika1999@yahoo.com>
2832
 
 */
2833
 
 
2834
 
/** \page selecttab selecttab
2835
 
 * \section Syntax
2836
 
 *
2837
 
 * selecttab ('\<window name\>', '\<tab list name\>', '\<tab name\>')
2838
 
 *
2839
 
 * \section Description
2840
 
 *
2841
 
 * Select the given tab name in the tab list
2842
 
 *
2843
 
 * \section ImplementationDetails
2844
 
 *
2845
 
 * \retval 1 if the tab is selected, \exception otherwise LdtpExecutionError will be thrown
2846
 
 *
2847
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/page-tab-list.c
2848
 
 *
2849
 
 * \section Example
2850
 
 *
2851
 
 * from ldtp import *
2852
 
 * 
2853
 
 * For selecting Editor tab with respect to gedit preferences
2854
 
 * 
2855
 
 * selecttab ('dlgPreferences', 'ptlPreferences', 'Editor') 
2856
 
 *
2857
 
 * \author Thanikachalam S <thanika1999@yahoo.com>
2858
 
 */
2859
 
 
2860
 
/** \page selecttabindex selecttabindex
2861
 
 * \section Syntax
2862
 
 *
2863
 
 * selecttabindex ('\<window name\>', '\<tab list name\>', \<index of the tab\>)
2864
 
 *
2865
 
 * \section Description
2866
 
 *
2867
 
 * Select a particular tab in the list of tabs
2868
 
 *
2869
 
 * \section ImplementationDetails
2870
 
 *
2871
 
 * \retval 1 if the tab is selected, \exception otherwise LdtpExecutionError will be thrown
2872
 
 *
2873
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/page-tab-list.c
2874
 
 *
2875
 
 * \section Example
2876
 
 *
2877
 
 * from ldtp import *
2878
 
 * 
2879
 
 * For selecting Editor tab with respect to gedit preferences
2880
 
 * 
2881
 
 * selecttabindex ('dlgPreferences', 'ptlPreferences', 1)
2882
 
 * 
2883
 
 * \note 0 based index
2884
 
 *
2885
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2886
 
 */
2887
 
 
2888
 
/** \page gettabcount gettabcount
2889
 
 * \section Syntax
2890
 
 *
2891
 
 * gettabcount ('\<window name\>', '\<tab list name\>')
2892
 
 *
2893
 
 * \section Description
2894
 
 *
2895
 
 * Returns the page tab count of a page tab list
2896
 
 *
2897
 
 * \retval tab count of type long is returned on success, LdtpExecutionError on failure
2898
 
 *
2899
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/page-tab-list.c
2900
 
 *
2901
 
 * \section Example
2902
 
 *
2903
 
 * With respect to Preferences dialog of gedit
2904
 
 *
2905
 
 * from ldtp import *
2906
 
 *
2907
 
 * selectmenuitem ('*-gedit', 'mnuEdit;mnuPreferences')
2908
 
 *
2909
 
 * gettabcount ('dlgPreferences', 'ptl0')
2910
 
 *
2911
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2912
 
 */
2913
 
 
2914
 
/** \page gettabname gettabname
2915
 
 * \section Syntax
2916
 
 *
2917
 
 * gettabname ('\<window name\>', '\<tab list name\>', \<index\>)
2918
 
 *
2919
 
 * \section Description
2920
 
 *
2921
 
 * Returns the page tab name of the given index in a page tab list
2922
 
 *
2923
 
 * \retval tab name is returned on success, LdtpExecutionError on failure
2924
 
 *
2925
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/page-tab-list.c
2926
 
 *
2927
 
 * \section Example
2928
 
 *
2929
 
 * With respect to Preferences dialog of gedit
2930
 
 *
2931
 
 * from ldtp import *
2932
 
 *
2933
 
 * selectmenuitem ('*-gedit', 'mnuEdit;mnuPreferences')
2934
 
 *
2935
 
 * gettabname ('dlgPreferences', 'ptl0', 0)
2936
 
 *
2937
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2938
 
 */
2939
 
 
2940
 
/** \page verifypushbutton verifypushbutton
2941
 
 * \section Syntax
2942
 
 *
2943
 
 * verifypushbutton ('\<window name\>', '\<component name\>')
2944
 
 *
2945
 
 * \section Description
2946
 
 *
2947
 
 * Verify whether the given object is push button or not.
2948
 
 *
2949
 
 * \section ImplementationDetails
2950
 
 *
2951
 
 * \retval 1 if object is push button, else 0.
2952
 
 *
2953
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/push-button.c
2954
 
 *
2955
 
 * \section Example
2956
 
 *
2957
 
 * With respect to gedit open dialog window, verify open button is push button or not.
2958
 
 * 
2959
 
 * verifypushbutton ('dlgOpenFile', 'btnOpen') 
2960
 
 *
2961
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2962
 
 */
2963
 
 
2964
 
/** \page stateenabled stateenabled
2965
 
 * \section Syntax
2966
 
 *
2967
 
 * stateenabled ('\<window name\>', '\<component name\>')
2968
 
 *
2969
 
 * \section Description
2970
 
 *
2971
 
 * Checks the radio button object state enabled or not
2972
 
 *
2973
 
 * \section ImplementationDetails
2974
 
 *
2975
 
 * \retval 1 if state is enabled, else 0.
2976
 
 *
2977
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/push-button.c
2978
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/radio-button.c
2979
 
 *
2980
 
 * \section Example
2981
 
 *
2982
 
 * Push button: With respect to gedit Open dialog, this function checks open button state enabled or not
2983
 
 * 
2984
 
 * stateenabled ('dlgOpenFile', 'btnOpen')
2985
 
 * 
2986
 
 * Radio button: With respect to gedit Print dialog, this function cheks the 'All' radio button state is enabled or not
2987
 
 *
2988
 
 * stateenabled ('Print', 'All')
2989
 
 * 
2990
 
 * Check box: With respect to gedit Print dialog, this function cheks the 'Reverse' check box state is enabled or not
2991
 
 *
2992
 
 * stateenabled ('Print', 'Reverse')
2993
 
 * 
2994
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
2995
 
 */
2996
 
 
2997
 
/** \page setvalue setvalue
2998
 
 * \section Syntax
2999
 
 *
3000
 
 * setvalue ('\<window name\>', '\<spinbutton name\>', \<value\>)
3001
 
 *
3002
 
 * \section Description
3003
 
 *
3004
 
 * Sets the value of the spin button.
3005
 
 *
3006
 
 * \section ImplementationDetails
3007
 
 *
3008
 
 * \retval 1 on success, else LdtpExecutionError exception
3009
 
 *
3010
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/spin-button.c
3011
 
 *
3012
 
 * \section Example
3013
 
 *
3014
 
 * Creation of Appointment in Evolution:
3015
 
 * 
3016
 
 * setvalue ('dlgAppointment-Nosummary','sbtnOccurence',2) 
3017
 
 *
3018
 
 * \author Thanikachalam S <thanika1999@yahoo.com>
3019
 
 */
3020
 
 
3021
 
/** \page getvalue getvalue
3022
 
 * \section Syntax
3023
 
 *
3024
 
 * getvalue ('\<window name\>', '\<spinbutton name\>')
3025
 
 *
3026
 
 * \section Description
3027
 
 *
3028
 
 * Gets the value in the spin button.
3029
 
 *
3030
 
 * \section ImplementationDetails
3031
 
 *
3032
 
 * \retval value in the spin button on success, else LdtpExecutionError exception
3033
 
 *
3034
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/spin-button.c
3035
 
 *
3036
 
 * \section Example
3037
 
 *
3038
 
 * Creation of Appointment in Evolution:
3039
 
 * 
3040
 
 * getvalue ('dlgAppointment-Nosummary', 'sbtnOccurence')
3041
 
 *
3042
 
 * \author Thanikachalam S <thanika1999@yahoo.com>
3043
 
 */
3044
 
 
3045
 
/** \page getmaxvalue getmaxvalue
3046
 
 * \section Syntax
3047
 
 *
3048
 
 * getmaxvalue ('\<window name\>', '\<spinbutton name\>')
3049
 
 *
3050
 
 * \section Description
3051
 
 *
3052
 
 * Gets the max value of the spin button.
3053
 
 *
3054
 
 * \section ImplementationDetails
3055
 
 *
3056
 
 * \retval max value of the spin button on success, else LdtpExecutionError exception
3057
 
 *
3058
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/spin-button.c
3059
 
 *
3060
 
 * \section Example
3061
 
 *
3062
 
 * Creation of Appointment in Evolution:
3063
 
 * 
3064
 
 * getmaxvalue ('dlgAppointment-Nosummary', 'sbtnOccurence')
3065
 
 *
3066
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
3067
 
 */
3068
 
 
3069
 
/** \page getminvalue getminvalue
3070
 
 * \section Syntax
3071
 
 *
3072
 
 * getminvalue ('\<window name\>', '\<spinbutton name\>')
3073
 
 *
3074
 
 * \section Description
3075
 
 *
3076
 
 * Gets the min value of the spin button.
3077
 
 *
3078
 
 * \section ImplementationDetails
3079
 
 *
3080
 
 * \retval min value of the spin button on success, else LdtpExecutionError exception
3081
 
 *
3082
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/spin-button.c
3083
 
 *
3084
 
 * \section Example
3085
 
 *
3086
 
 * Creation of Appointment in Evolution:
3087
 
 * 
3088
 
 * getminvalue ('dlgAppointment-Nosummary', 'sbtnOccurence')
3089
 
 *
3090
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
3091
 
 */
3092
 
 
3093
 
/** \page getminincrement getminincrement
3094
 
 * \section Syntax
3095
 
 *
3096
 
 * getminincrement ('\<window name\>', '\<spinbutton name\>')
3097
 
 *
3098
 
 * \section Description
3099
 
 *
3100
 
 * Gets the min value of the spin button.
3101
 
 *
3102
 
 * \section ImplementationDetails
3103
 
 *
3104
 
 * \retval min value of the spin button on success, else LdtpExecutionError exception
3105
 
 *
3106
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/spin-button.c
3107
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/slider.c
3108
 
 *
3109
 
 * \section Example
3110
 
 *
3111
 
 * Creation of Appointment in Evolution:
3112
 
 * 
3113
 
 * getminincrement ('dlgAppointment-Nosummary', 'sbtnOccurence')
3114
 
 *
3115
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
3116
 
 */
3117
 
 
3118
 
/** \page verifysetvalue verifysetvalue
3119
 
 * \section Syntax
3120
 
 *
3121
 
 * verifysetvalue ('\<window name\>', '\<spinbutton name\>', '\<value\>')
3122
 
 *
3123
 
 * \section Description
3124
 
 *
3125
 
 * Verifies the value set in spin button.
3126
 
 *
3127
 
 * \section ImplementationDetails
3128
 
 *
3129
 
 * \retval 1 on success and 0 on error.
3130
 
 *
3131
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/spin-button.c
3132
 
 *
3133
 
 * \section Example
3134
 
 *
3135
 
 * In the Creation of Appointment:
3136
 
 * 
3137
 
 * verifysetvalue ('dlgAppointment-Nosummary','sbtnOccurence','2') 
3138
 
 *
3139
 
 * \author Sheetal <svnayak18@yahoo.com>
3140
 
 */
3141
 
 
3142
 
/** \page selectrow selectrow
3143
 
 * \section Syntax
3144
 
 *
3145
 
 * selectrow ('\<window name\>', '\<table name\>', '\<value of row in first column\>')
3146
 
 *
3147
 
 * \section Description
3148
 
 *
3149
 
 * Selects the row in table whose first column's (0th column) value is same as the contents of the third argument in the function call.
3150
 
 *
3151
 
 * \section ImplementationDetails
3152
 
 *
3153
 
 * \retval 1 on success and 0 on error.
3154
 
 *
3155
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/table.c
3156
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
3157
 
 *
3158
 
 * \section Example
3159
 
 *
3160
 
 * from ldtp import *
3161
 
 * 
3162
 
 * With respect to gedit open dialog
3163
 
 * 
3164
 
 * selectrow ('dlgOpen', 'dlgFiles', 'readme') 
3165
 
 *
3166
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
3167
 
 */
3168
 
 
3169
 
/** \page selectrowindex selectrowindex
3170
 
 * \section Syntax
3171
 
 *
3172
 
 * selectrowindex ('\<window name\>', '\<table name\>', \<row index\>) 
3173
 
 *
3174
 
 * \section Description
3175
 
 *
3176
 
 * Selects the row with the given index value in table. Index value starts from 0.
3177
 
 *
3178
 
 * \section ImplementationDetails
3179
 
 *
3180
 
 * \retval 1 on success and 0 on error.
3181
 
 *
3182
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/table.c
3183
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
3184
 
 *
3185
 
 * \section Example
3186
 
 *
3187
 
 * from ldtp import *
3188
 
 * 
3189
 
 * With respect to gedit open dialog
3190
 
 * 
3191
 
 * selectrowindex ('dlgOpen', 'dlgFiles', 0) 
3192
 
 *
3193
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
3194
 
 */
3195
 
 
3196
 
/** \page selectrowpartialmatch selectrowpartialmatch
3197
 
 * \section Syntax
3198
 
 *
3199
 
 * selectrowpartialmatch ('\<window name\>', '\<tree table name\>', '\<texttobesearchedfor\>')
3200
 
 *
3201
 
 * \section Description
3202
 
 *
3203
 
 * selects the row having cell that contains the given text.
3204
 
 *
3205
 
 * \section ImplementationDetails
3206
 
 *
3207
 
 * \retval 1 on success and throws an exception on error
3208
 
 *
3209
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/table.c
3210
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
3211
 
 *
3212
 
 * \section Example
3213
 
 *
3214
 
 * With respect to evolution
3215
 
 * 
3216
 
 * selectrowpartialmatch ('evolution', 'ttblMailFolder','Inbox')
3217
 
 * 
3218
 
 * The 'Inbox' folder's name changes depending on the number of unread mails. In such cases we can use the above method to select the 'Inbox' folder. 
3219
 
 *
3220
 
 * \author Nagashree <mnagashree@novell.com>
3221
 
 */
3222
 
 
3223
 
/** \page verifytoggled verifytoggled
3224
 
 * \section Syntax
3225
 
 *
3226
 
 * verifytoggled ('<window name\>', 'component name\>')
3227
 
 *
3228
 
 * \section Description
3229
 
 *
3230
 
 * Verify whether the toggle button is toggled or not
3231
 
 *
3232
 
 * \retval 1 on success, else 0
3233
 
 *
3234
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/toggle-button.c
3235
 
 *
3236
 
 * \section Example
3237
 
 *
3238
 
 * 1. With respect to GTK File Selector - Open dialog in gedit application
3239
 
 *
3240
 
 * from ldtp import *
3241
 
 *
3242
 
 * verifytoggled ('Open File*', 'Type a file name') # If 'Type a file name' button is toggled then location text box will be in editable state in GTK file selector
3243
 
 *
3244
 
 * 2. With respect to GTK File Selector in gedit
3245
 
 *
3246
 
 * from ldtp import *
3247
 
 *
3248
 
 * click ('*-gedit', 'btnOpen')
3249
 
 *
3250
 
 * verifytoggled ('dlgOpenFile...', 'tbtnTypeafilename')
3251
 
 *
3252
 
 * \author Poornima Nayak <pnayak@novell.com>
3253
 
 * \author Premkumar J <prem.jothimani@gmail.com> 
3254
 
 */
3255
 
 
3256
 
/** \page onedown onedown
3257
 
 * \section Syntax
3258
 
 *
3259
 
 * onedown ('\<window name\>', '\<scroll component name\>', \<number of iterations\>)
3260
 
 *
3261
 
 * \section Description
3262
 
 *
3263
 
 * Move the scroll bar down 'n' times, where 'n' is the number of iterations specified in the argument field.
3264
 
 *
3265
 
 * \section ImplementationDetails
3266
 
 *
3267
 
 * Scrolls down if value does not exceed the maximum limit, else fails.
3268
 
 *
3269
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/scroll-bar.c
3270
 
 *
3271
 
 * \section Example
3272
 
 *
3273
 
 * from ldtp import *
3274
 
 * 
3275
 
 * For scroll bar item with respect to gedit
3276
 
 * 
3277
 
 * onedown ('gedit', 'scrollBar', 3) 
3278
 
 *
3279
 
 * \author Aishwariya & Kamakshi <poorvaishoo@yahoo.com>
3280
 
 */
3281
 
 
3282
 
/** \page oneleft oneleft
3283
 
 * \section Syntax
3284
 
 *
3285
 
 * oneleft ('\<window name\>', '\<scroll component name\>', \<number of iterations\>)
3286
 
 *
3287
 
 * \section Description
3288
 
 *
3289
 
 * Move the (horizontal) scroll bar left 'n' times, where 'n' is the number of iterations specified in the argument field.
3290
 
 *
3291
 
 * \section ImplementationDetails
3292
 
 *
3293
 
 * Scrolls left if value does not drop below the minimum limit, else fails.
3294
 
 *
3295
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/scroll-bar.c
3296
 
 *
3297
 
 * \section Example
3298
 
 *
3299
 
 * from ldtp import *
3300
 
 * 
3301
 
 * For scroll bar item with respect to gedit
3302
 
 * 
3303
 
 * oneleft ('gedit', 'scrollBar', 3) 
3304
 
 *
3305
 
 * \author Aishwariya & Kamakshi <poorvaishoo@yahoo.com>
3306
 
 */
3307
 
 
3308
 
/** \page oneright oneright
3309
 
 * \section Syntax
3310
 
 *
3311
 
 * oneright ('\<window name\>', '\<scroll component name\>', \<number of iterations\>)
3312
 
 *
3313
 
 * \section Description
3314
 
 *
3315
 
 * Move the (horizontal) scroll bar right 'n' times, where 'n' is the number of iterations specified in the argument field.
3316
 
 *
3317
 
 * \section ImplementationDetails
3318
 
 *
3319
 
 * Scrolls right if value does not exceed the maximum limit, else fails.
3320
 
 *
3321
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/scroll-bar.c
3322
 
 *
3323
 
 * \section Example
3324
 
 *
3325
 
 * from ldtp import *
3326
 
 * 
3327
 
 * For scroll bar item with respect to gedit
3328
 
 * 
3329
 
 * oneright ('gedit', 'scrollBar', 3) 
3330
 
 *
3331
 
 * \author Aishwariya & Kamakshi <poorvaishoo@yahoo.com>
3332
 
 */
3333
 
 
3334
 
/** \page oneup oneup
3335
 
 * \section Syntax
3336
 
 *
3337
 
 * oneup ('\<window name\>', '\<scroll component name\>', \<number of iterations\>)
3338
 
 *
3339
 
 * \section Description
3340
 
 *
3341
 
 * Move the (vertical) scroll bar up 'n' times, where 'n' is the number of iterations specified in the argument field.
3342
 
 *
3343
 
 * \section ImplementationDetails
3344
 
 *
3345
 
 * Scrolls up if value does not drop below the minimum limit, else fails.
3346
 
 *
3347
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/scroll-bar.c
3348
 
 *
3349
 
 * \section Example
3350
 
 *
3351
 
 * from ldtp import *
3352
 
 * 
3353
 
 * For scroll bar item with respect to gedit
3354
 
 * 
3355
 
 * oneup ('gedit', 'scrollBar', 3) 
3356
 
 *
3357
 
 * \author Aishwariya & Kamakshi <poorvaishoo@yahoo.com>
3358
 
 */
3359
 
 
3360
 
/** \page scrolldown scrolldown
3361
 
 * \section Syntax
3362
 
 *
3363
 
 * scrolldown ('\<window name\>', '\<scroll component name\>')
3364
 
 *
3365
 
 * \section Description
3366
 
 *
3367
 
 * Move the (vertical) scroll bar to the bottom.
3368
 
 *
3369
 
 * \section ImplementationDetails
3370
 
 *
3371
 
 * \retval 1 if action is performed, else 0.
3372
 
 *
3373
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/scroll-bar.c
3374
 
 *
3375
 
 * \section Example
3376
 
 *
3377
 
 * from ldtp import *
3378
 
 * 
3379
 
 * For scroll bar item with respect to gedit
3380
 
 * 
3381
 
 * scrolldown ('gedit', 'scrollBar') 
3382
 
 *
3383
 
 * \author Aishwariya & Kamakshi <poorvaishoo@yahoo.com>
3384
 
 */
3385
 
 
3386
 
/** \page scrollleft scrollleft
3387
 
 * \section Syntax
3388
 
 *
3389
 
 * scrolleft ('\<window name\>', '\<scroll component name\>')
3390
 
 *
3391
 
 * \section Description
3392
 
 *
3393
 
 * Move the (horizontal) scroll bar to the extreme left.
3394
 
 *
3395
 
 * \section ImplementationDetails
3396
 
 *
3397
 
 * \retval 1 if action is performed, else 0.
3398
 
 *
3399
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/scroll-bar.c
3400
 
 *
3401
 
 * \section Example
3402
 
 *
3403
 
 * from ldtp import *
3404
 
 * 
3405
 
 * For scroll bar item with respect to gedit
3406
 
 * 
3407
 
 * scrolleft ('gedit', 'scrollBar') 
3408
 
 *
3409
 
 * \author Aishwariya & Kamakshi <poorvaishoo@yahoo.com>
3410
 
 */
3411
 
 
3412
 
/** \page scrollright scrollright
3413
 
 * \section Syntax
3414
 
 *
3415
 
 * scrollright ('\<window name\>', '\<scroll component name\>')
3416
 
 *
3417
 
 * \section Description
3418
 
 *
3419
 
 * Move the (horizontal) scroll bar to the extreme right.
3420
 
 *
3421
 
 * \section ImplementationDetails
3422
 
 *
3423
 
 * \retval 1 if action is performed, else 0.
3424
 
 *
3425
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/scroll-bar.c
3426
 
 *
3427
 
 * \section Example
3428
 
 *
3429
 
 * from ldtp import *
3430
 
 * 
3431
 
 * For scroll bar item with respect to gedit
3432
 
 * 
3433
 
 * scrollright ('gedit', 'scrollBar') 
3434
 
 *
3435
 
 * \author Aishwariya & Kamakshi <poorvaishoo@yahoo.com>
3436
 
 */
3437
 
 
3438
 
/** \page scrollup scrollup
3439
 
 * \section Syntax
3440
 
 *
3441
 
 * scrollup ('\<window name\>', '\<scroll component name\>')
3442
 
 *
3443
 
 * \section Description
3444
 
 *
3445
 
 * Move the (vertical) scroll bar to the extreme top.
3446
 
 *
3447
 
 * \section ImplementationDetails
3448
 
 *
3449
 
 * \retval 1 if action is performed, else 0.
3450
 
 *
3451
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/scroll-bar.c
3452
 
 *
3453
 
 * \section Example
3454
 
 *
3455
 
 * from ldtp import *
3456
 
 * 
3457
 
 * For scroll bar item with respect to gedit
3458
 
 * 
3459
 
 * scrollup ('gedit', 'scrollBar') 
3460
 
 *
3461
 
 * \author Aishwariya & Kamakshi <poorvaishoo@yahoo.com>
3462
 
 */
3463
 
 
3464
 
/** \page setmax setmax
3465
 
 * \section Syntax
3466
 
 *
3467
 
 * setmax ('\<window name\>', '\<slider name\>')
3468
 
 *
3469
 
 * \section Description
3470
 
 *
3471
 
 * Set the slider to the maximum value.
3472
 
 *
3473
 
 * \section ImplementationDetails
3474
 
 *
3475
 
 * \retval 1 if action is performed, else 0.
3476
 
 *
3477
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/slider.c
3478
 
 *
3479
 
 * \section Example
3480
 
 *
3481
 
 * from ldtp import *
3482
 
 * 
3483
 
 * For slider component with respect to gnome-terminal
3484
 
 * 
3485
 
 * setmax ('dlgEditingProfile"Default"', 'slider') 
3486
 
 *
3487
 
 * \author Aishwariya & Kamakshi <poorvaishoo@yahoo.com>
3488
 
 */
3489
 
 
3490
 
/** \page setmin setmin
3491
 
 * \section Syntax
3492
 
 *
3493
 
 * setmin ('\<window name\>', '\<slider name\>')
3494
 
 *
3495
 
 * \section Description
3496
 
 *
3497
 
 * Set the slider to the minimum value.
3498
 
 *
3499
 
 * \section ImplementationDetails
3500
 
 *
3501
 
 * \retval 1 if action is performed, else 0.
3502
 
 *
3503
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/slider.c
3504
 
 *
3505
 
 * \section Example
3506
 
 *
3507
 
 * from ldtp import *
3508
 
 * 
3509
 
 * For slider component with respect to gnome-terminal
3510
 
 * 
3511
 
 * setmin ('dlgEditingProfile"Default"', 'slider') 
3512
 
 *
3513
 
 * \author Aishwariya & Kamakshi <poorvaishoo@yahoo.com>
3514
 
 */
3515
 
 
3516
 
/** \page getslidervalue getslidervalue
3517
 
 * \section Syntax
3518
 
 *
3519
 
 * getslidervalue ('\<window name\>', '\<slider name\>')
3520
 
 *
3521
 
 * \section Description
3522
 
 *
3523
 
 * Returns the slider value of the given object. Volume controller of type slider
3524
 
 *
3525
 
 * \retval slider value of type float is returned on success, LdtpExecutionError on failure
3526
 
 *
3527
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/slider.c
3528
 
 *
3529
 
 * \section Example
3530
 
 *
3531
 
 * \todo
3532
 
 *
3533
 
 * \author Aishwariya & Kamakshi <poorvaishoo@yahoo.com>
3534
 
 */
3535
 
 
3536
 
/** \page increase increase
3537
 
 * \section Syntax
3538
 
 *
3539
 
 * increase ('\<window name\>', '\<slider name\>', \<number of iterations\>)
3540
 
 *
3541
 
 * \section Description
3542
 
 *
3543
 
 * Increase the value of the slider 'n' times, where 'n' is the number of iterations specified in the argument field.
3544
 
 *
3545
 
 * \section ImplementationDetails
3546
 
 *
3547
 
 * Increases the value if it does not exceed the maximum limit, else fails.
3548
 
 *
3549
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/slider.c
3550
 
 *
3551
 
 * \section Example
3552
 
 *
3553
 
 * from ldtp import *
3554
 
 
3555
 
 * For slider component with respect to gnome-terminal
3556
 
 * 
3557
 
 * increase ('dlgEditingProfile"Default"', 'slider', 3) 
3558
 
 *
3559
 
 * \author Aishwariya & Kamakshi <poorvaishoo@yahoo.com>
3560
 
 */
3561
 
 
3562
 
/** \page decrease decrease
3563
 
 * \section Syntax
3564
 
 *
3565
 
 * decrease ('\<window name\>', '\<slider name\>', \<number of iterations\>)
3566
 
 *
3567
 
 * \section Description
3568
 
 *
3569
 
 * Decrease the value of the slider 'n' times, where 'n' is the number of iterations specified in the argument field.
3570
 
 *
3571
 
 * \section ImplementationDetails
3572
 
 *
3573
 
 * Decreases the value if it does not fall below the minimum limit, else fails.
3574
 
 *
3575
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/slider.c
3576
 
 *
3577
 
 * \section Example
3578
 
 *
3579
 
 * from ldtp import *
3580
 
 * 
3581
 
 * For slider component with respect to gnome-terminal
3582
 
 * 
3583
 
 * decrease ('dlgEditingProfile"Default"', 'slider', 3) 
3584
 
 *
3585
 
 * \author Aishwariya & Kamakshi <poorvaishoo@yahoo.com>
3586
 
 */
3587
 
 
3588
 
/** \page selectpanel selectpanel
3589
 
 * \section Syntax
3590
 
 *
3591
 
 * selectpanel ('\<window name\>', '\<component name\>', \<panel number\>)
3592
 
 *
3593
 
 * \section Description
3594
 
 *
3595
 
 * Select a panel using the panel number in a list of panels
3596
 
 *
3597
 
 * \section ImplementationDetails
3598
 
 *
3599
 
 * \retval 1 on success and 0 on error
3600
 
 *
3601
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/panel.c
3602
 
 *
3603
 
 * \section Example
3604
 
 *
3605
 
 * from ldtp import *
3606
 
 * 
3607
 
 * With respect to Evolution Contacts
3608
 
 * 
3609
 
 * selectpanel ('frmEvolution-Contacts', 'pnlAddbook', 1) 
3610
 
 *
3611
 
 * \author Poornima Nayak <pnayak@novell.com>
3612
 
 */
3613
 
 
3614
 
/** \page selectlabelspanelbyname selectlabelspanelbyname
3615
 
 * \section Syntax
3616
 
 *
3617
 
 * selectlabelspanelbyname ('<window name\>', '<label name\>')
3618
 
 *
3619
 
 * \section Description
3620
 
 *
3621
 
 * \retval 1 on success, LdtpExecutionError on failure
3622
 
 *
3623
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/label.c
3624
 
 *
3625
 
 * \section Example
3626
 
 *
3627
 
 * \todo
3628
 
 *
3629
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
3630
 
 */
3631
 
 
3632
 
/** \page verifytablecell verifytablecell
3633
 
 * \section Syntax
3634
 
 *
3635
 
 * verifytablecell ('\<window name\>', '\<table name\>', \<row no\>, \<column no\>, '\<string to be compared\>')
3636
 
 *
3637
 
 * \section Description
3638
 
 *
3639
 
 * Verifies the tablecell value with the String Passed ie., fifth argument
3640
 
 *
3641
 
 * \section ImplementationDetails
3642
 
 *
3643
 
 * \retval 1 on success and 0 on error.
3644
 
 *
3645
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/table.c
3646
 
 *
3647
 
 * \section Example
3648
 
 *
3649
 
 * from ldtp import *
3650
 
 * 
3651
 
 * With respect to Evolution, open message
3652
 
 * 
3653
 
 * verifytablecell ('frmReadOnlyMail', 'tblcheck', 1, 1, 'xyz\@yahoo.com') 
3654
 
 *
3655
 
 * \author Bhargavi <kbhargavi_83@yahoo.co.in>
3656
 
 */
3657
 
 
3658
 
/** \page setcellvalue setcellvalue
3659
 
 * \section Syntax
3660
 
 *
3661
 
 * setcellvalue ('<window name\>', '<table name\>', <row\>, <column\>, '<item\>')
3662
 
 *
3663
 
 * \section Description
3664
 
 *
3665
 
 * \retval 1 on success, LdtpExecutionError exception on failure
3666
 
 *
3667
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/table.c
3668
 
 *
3669
 
 * \section Example
3670
 
 *
3671
 
 * \todo
3672
 
 *
3673
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
3674
 
 */
3675
 
 
3676
 
/** \page selectlastrow selectlastrow
3677
 
 * \section Syntax
3678
 
 *
3679
 
 * selectlastrow ('\<window name\>', '\<table name\>')
3680
 
 *
3681
 
 * \section Description
3682
 
 *
3683
 
 * Selects the last row of a table.
3684
 
 *
3685
 
 * \retval 1 on success, 0 otherwise.
3686
 
 *
3687
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/table.c
3688
 
 *
3689
 
 * \section Example
3690
 
 *
3691
 
 * from ldtp import *
3692
 
 * 
3693
 
 * With respect to Contact List Members dialog of Contact List Editor
3694
 
 * 
3695
 
 * selectlastrow ('dlgContactListMembers', 'tblContacts') 
3696
 
 *
3697
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
3698
 
 */
3699
 
 
3700
 
/** \page setcontext setcontext
3701
 
 * \section Syntax
3702
 
 *
3703
 
 * setcontext ('\<previous title name\>', '\<new title name\>')
3704
 
 *
3705
 
 * \section Description
3706
 
 *
3707
 
 * LDTP selects window (frame / dialog / alert / font chooser) based on the title name.
3708
 
 *
3709
 
 * \section ImplementationDetails
3710
 
 *
3711
 
 * set the context to new title name. Changes are done in is_matching function in gui.c
3712
 
 *
3713
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
3714
 
 *
3715
 
 * \section Example
3716
 
 *
3717
 
 * In some applications the window title changes based on the operation we are doing. For example, when we browse any URL in Firefox browser, the title bar changes. Once title bar changed, then we can change the context using this function.
3718
 
 * 
3719
 
 * setcontext ('Mozilla Firefox', 'NOVELL: Novell and Linux - Mozilla Firefox') 
3720
 
 *
3721
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
3722
 
 */
3723
 
 
3724
 
/** \page releasecontext releasecontext
3725
 
 * \section Syntax
3726
 
 *
3727
 
 * releasecontext ()
3728
 
 *
3729
 
 * \section Description
3730
 
 *
3731
 
 * Release the last context set.
3732
 
 *
3733
 
 * \section ImplementationDetails
3734
 
 *
3735
 
 * Release the existing (last) context set using \ref setcontext function.
3736
 
 *
3737
 
 * \retval 1 on success, LdtpExecutionError on failure
3738
 
 *
3739
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
3740
 
 *
3741
 
 * \section Example
3742
 
 *
3743
 
 * In some applications the window title changes based on the operation we are doing. For example, when we browse any URL in Firefox browser, the title bar changes. Once title bar changed, then we can change the context using this function.
3744
 
 * 
3745
 
 * releasecontext () 
3746
 
 *
3747
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
3748
 
 */
3749
 
 
3750
 
/** \page selectevent selectevent
3751
 
 * \section Syntax
3752
 
 *
3753
 
 * selectevent ('\<window name\>', '\<Calendar_view name\>', '\<calendar event summary\>')
3754
 
 *
3755
 
 * \section Description
3756
 
 *
3757
 
 * Selects the row from the table of calendar events based on the calendar event name specified
3758
 
 *
3759
 
 * \section ImplementationDetails
3760
 
 *
3761
 
 * \retval 1 on success, else 0.
3762
 
 *
3763
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/calendar-view.c
3764
 
 *
3765
 
 * \section Example
3766
 
 *
3767
 
 * In Evolution Calendars,for selecting an appointment-(calendar event) present in the table
3768
 
 * 
3769
 
 * from ldtp import *
3770
 
 * 
3771
 
 * selectevent ('Evolution-Calendars', 'calview', 'abc') 
3772
 
 *
3773
 
 * \author Poornima <pnayak@novell.com>
3774
 
 */
3775
 
 
3776
 
/** \page selecteventindex selecteventindex
3777
 
 * \section Syntax
3778
 
 *
3779
 
 * selecteventindex ('\<window name\>', '\<component name\>', \<event number\>)
3780
 
 *
3781
 
 * \section Description
3782
 
 *
3783
 
 * Select an event from a calendar table using its index. Index for a calendar event starts from 1.
3784
 
 *
3785
 
 * \section ImplementationDetails
3786
 
 *
3787
 
 * \retval 1 on success, else 0
3788
 
 *
3789
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/calendar-view.c
3790
 
 *
3791
 
 * \section Example
3792
 
 *
3793
 
 * from ldtp import *
3794
 
 * 
3795
 
 * With respect to Evolution-Calendars
3796
 
 * 
3797
 
 * selecteventindex ('Evolution-Calendars', 'calview', 1) 
3798
 
 *
3799
 
 * \author Poornima <pnayak@novell.com>
3800
 
 */
3801
 
 
3802
 
/** \page doesrowexist doesrowexist
3803
 
 * \section Syntax
3804
 
 *
3805
 
 * doesrowexist ('\<window name\>', '\<table name\>', '\<string to be
3806
 
 * matched\>'[, \<partial match = False\>])
3807
 
 *
3808
 
 * \section Description
3809
 
 *
3810
 
 * Checks whether the table contains any row with any of its cell
3811
 
 * containing the given string as its value.Please note that it checks
3812
 
 * for an exact match, if partial match is set to False. 
3813
 
 *
3814
 
 * \section ImplementationDetails
3815
 
 *
3816
 
 * \retval 1 if there are rows with the given string in any of its cell, else 0.
3817
 
 *
3818
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/table.c
3819
 
 *
3820
 
 * \section Example
3821
 
 *
3822
 
 * from ldtp import *
3823
 
 * 
3824
 
 * With respect to the message list table in Evolution Mailer, the following call will return 1 if there is atleast one mail in the list with the given string in the subject field or sender field or in any other field for that matter.
3825
 
 * 
3826
 
 * doesrowexist ('dlgContactListMembers', 'tblContacts', 'Sample subject') 
3827
 
 * 
3828
 
 * doesrowexist ('dlgContactListMembers', 'tblContacts', 'Sample', True) 
3829
 
 *
3830
 
 * \author Manu <manunature@rediffmail.com>
3831
 
 */
3832
 
 
3833
 
/** \page checkrow checkrow
3834
 
 * \section Syntax
3835
 
 *
3836
 
 * checkrow ('\<window name\>', '\<table name\>', \<row index\>[, \<col index\>])
3837
 
 *
3838
 
 * \section Description
3839
 
 *
3840
 
 * checks the row with the given index value in table. This can take an optional column index and perform the action on that particular column. If the column index is not given, 0 is taken as the default value.Index value starts from 0. 
3841
 
 *
3842
 
 * \section ImplementationDetails
3843
 
 *
3844
 
 * \retval 1 on success, else 0.
3845
 
 *
3846
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
3847
 
 *
3848
 
 * \section Example
3849
 
 *
3850
 
 * from ldtp import *
3851
 
 * 
3852
 
 * With respect to Categories in Appointment in Evolution
3853
 
 * 
3854
 
 * checkrow('dlgCategories','tblcategories',3) 
3855
 
 *
3856
 
 * \author Bhargavi <kbhargavi_83@yahoo.co.in>
3857
 
 */
3858
 
 
3859
 
/** \page verifycheckrow verifycheckrow
3860
 
 * \section Syntax
3861
 
 *
3862
 
 * verifycheckrow ('\<window name\>', '\<table name\>', \<row index\>[, \<col index\>])
3863
 
 *
3864
 
 * \section Description
3865
 
 *
3866
 
 * 
3867
 
 *
3868
 
 * \section ImplementationDetails
3869
 
 *
3870
 
 * \retval 1 on success, else 0.
3871
 
 *
3872
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
3873
 
 *
3874
 
 * \section Example
3875
 
 *
3876
 
 * from ldtp import *
3877
 
 * 
3878
 
 * With respect to Categories in Appointment in Evolution
3879
 
 * 
3880
 
 * verifycheckrow ('dlgCategories', 'tblcategories', 3)
3881
 
 *
3882
 
 * \author Bhargavi <kbhargavi_83@yahoo.co.in>
3883
 
 */
3884
 
 
3885
 
/** \page uncheckrow uncheckrow
3886
 
 * \section Syntax
3887
 
 *
3888
 
 * uncheckrow ('\<window name\>', '\<table name\>', \<row index\>[, \<col index\>])
3889
 
 *
3890
 
 * \section Description
3891
 
 *
3892
 
 * unchecks the row with the given index value in table. This can take an optional column index and perform the action on that particular column. If the column index is not given, 0 is taken as the default value.Index value starts from 0. 
3893
 
 *
3894
 
 * \section ImplementationDetails
3895
 
 *
3896
 
 * \retval 1 on success, else 0.
3897
 
 *
3898
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
3899
 
 *
3900
 
 * \section Example
3901
 
 *
3902
 
 * from ldtp import *
3903
 
 * 
3904
 
 * With respect to Categories in Appointment in Evolution
3905
 
 * 
3906
 
 * uncheckrow('dlgCategories','tblcategories',3) 
3907
 
 *
3908
 
 * \author Bhargavi <kbhargavi_83@yahoo.co.in>
3909
 
 */
3910
 
 
3911
 
/** \page verifyuncheckrow verifyuncheckrow
3912
 
 * \section Syntax
3913
 
 *
3914
 
 * verifyuncheckrow ('\<window name\>', '\<table name\>', \<row index\>[, \<col index\>])
3915
 
 *
3916
 
 * \section Description
3917
 
 *
3918
 
 *
3919
 
 *
3920
 
 * \section ImplementationDetails
3921
 
 *
3922
 
 * \retval 1 on success, else 0.
3923
 
 *
3924
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
3925
 
 *
3926
 
 * \section Example
3927
 
 *
3928
 
 * from ldtp import *
3929
 
 * 
3930
 
 * With respect to Categories in Appointment in Evolution
3931
 
 * 
3932
 
 * verifyuncheckrow ('dlgCategories', 'tblcategories', 3) 
3933
 
 *
3934
 
 * \author Bhargavi <kbhargavi_83@yahoo.co.in>
3935
 
 */
3936
 
 
3937
 
/** \page sortcolumn sortcolumn
3938
 
 * \section Syntax
3939
 
 *
3940
 
 * sortcolumn ('<window name\>', '<table name\>', '<column name\>')
3941
 
 *
3942
 
 * \section Description
3943
 
 *
3944
 
 * Sort table based on column name.
3945
 
 *
3946
 
 * \retval 1 on success, LdtpExecutionError exception on failure
3947
 
 *
3948
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
3949
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/table.c
3950
 
 *
3951
 
 * \section Example
3952
 
 *
3953
 
 * \todo
3954
 
 *
3955
 
 * \author 
3956
 
 */
3957
 
 
3958
 
/** \page sortcolumnindex sortcolumnindex
3959
 
 * \section Syntax
3960
 
 *
3961
 
 * sortcolumnindex ('<window name\>', '<table name\>', <column index\>)
3962
 
 *
3963
 
 * \section Description
3964
 
 *
3965
 
 * Sort table based on column index.
3966
 
 *
3967
 
 * \retval 1 on success, LdtpExecutionError exception on failure
3968
 
 *
3969
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
3970
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/table.c
3971
 
 *
3972
 
 * \section Example
3973
 
 *
3974
 
 * \todo
3975
 
 *
3976
 
 * \author 
3977
 
 */
3978
 
 
3979
 
/** \page verifypartialmatch verifypartialmatch
3980
 
 * \section Syntax
3981
 
 *
3982
 
 * verifypartialmatch ('\<window name\>', '\<textbox name\>' , '\<substring\>' )
3983
 
 *
3984
 
 * \section Description
3985
 
 *
3986
 
 * Verifies the textbox with the partial string
3987
 
 *
3988
 
 * \section ImplementationDetails
3989
 
 *
3990
 
 * \retval 1 on success, else 0.
3991
 
 *
3992
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
3993
 
 *
3994
 
 * \section Example
3995
 
 *
3996
 
 * from ldtp import *
3997
 
 * 
3998
 
 * With respect to Evolution, to verify textbox with partial string
3999
 
 * 
4000
 
 * verifypartialmatch ('frmComposeamessage', 'txtto','nove') 
4001
 
 *
4002
 
 * \author Bhargavi <kbhargavi_83yahoo.co.in>
4003
 
 */
4004
 
 
4005
 
/** \page getrowcount getrowcount
4006
 
 * \section Syntax
4007
 
 *
4008
 
 * getrowcount ('\<window name\>', '\<table name\>')
4009
 
 *
4010
 
 * \section Description
4011
 
 *
4012
 
 * Returns the number of rows present in the table mentioned
4013
 
 *
4014
 
 * \retval number of rows present in the table on success, else -1
4015
 
 *
4016
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/table.c
4017
 
 * \n
4018
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
4019
 
 *
4020
 
 * \section Example
4021
 
 *
4022
 
 * from ldtp import *
4023
 
 * 
4024
 
 * With respect to Evolution, to check no of mails
4025
 
 * 
4026
 
 * getrowcount ('frmReadOnlyMail', 'tblmails')
4027
 
 *
4028
 
 * \author Bhargavi <kbhargavi_83@yahoo.co.in>
4029
 
 */
4030
 
 
4031
 
/** \page verifypartialtablecell verifypartialtablecell
4032
 
 * \section Syntax
4033
 
 *
4034
 
 * verifypartialtablecell ('\<window name\>', '\<table name\>', \<row no\>, \<column no\>, '\<sub string to be compared\>')
4035
 
 *
4036
 
 * \section Description
4037
 
 *
4038
 
 * Verifies the tablecell value with the sub String Passed ie., fifth argument
4039
 
 *
4040
 
 * \section ImplementationDetails
4041
 
 *
4042
 
 * \retval 1 on success, else 0.
4043
 
 *
4044
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/table.c
4045
 
 *
4046
 
 * \section Example
4047
 
 *
4048
 
 * from ldtp import *
4049
 
 * 
4050
 
 * With respect to Evolution, open message
4051
 
 * 
4052
 
 * verifypartialtablecell ('frmReadOnlyMail', 'tblcheck', 1, 1, 'xyz') 
4053
 
 *
4054
 
 * \author Bhargavi <kbhargavi_83@yahoo.co.in>
4055
 
 */
4056
 
 
4057
 
/** \page grabfocus grabfocus
4058
 
 * \section Syntax
4059
 
 *
4060
 
 * grabfocus ('\<window name\>'[, '\<component name\>'])
4061
 
 *
4062
 
 * \section Description
4063
 
 *
4064
 
 * gives focus to the specified context or component, in case of a text box the cursor is placed in it.
4065
 
 *
4066
 
 * \section ImplementationDetails
4067
 
 *
4068
 
 * \retval 1 on success, else LdtpExecutionError exception
4069
 
 *
4070
 
 * \section Example
4071
 
 *
4072
 
 * With respect to gnome search tool structure
4073
 
 * 
4074
 
 * settextvalue ('SearchforFiles', 'txtNameContainsEntry')
4075
 
 * 
4076
 
 * This places the cursor in the 'txtNameContainsEntry' field. 
4077
 
 *
4078
 
 */
4079
 
 
4080
 
/** \page selectpanelname selectpanelname
4081
 
 * \section Syntax
4082
 
 *
4083
 
 * selectpanelname ('\<window name\>', '\<component name\>', '\<panel name\>')
4084
 
 *
4085
 
 * \section Description
4086
 
 *
4087
 
 * Select a panel using the panel name in a list of panels
4088
 
 *
4089
 
 * \section ImplementationDetails
4090
 
 *
4091
 
 * \retval 1 on success, else LdtpExecutionError exception
4092
 
 *
4093
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/panel.c
4094
 
 *
4095
 
 * \section Example
4096
 
 *
4097
 
 * from ldtp import *
4098
 
 * 
4099
 
 * With respect to Evolution Contacts
4100
 
 * 
4101
 
 * selectpanelname ('Evolution-Contacts', 'pnlAddbook', 'ldtp') 
4102
 
 *
4103
 
 * \author Khasim Shaheed <khasim.shaheed@gmail.com>
4104
 
 */
4105
 
 
4106
 
/** \page verifyeventexist verifyeventexist
4107
 
 * \section Syntax
4108
 
 *
4109
 
 * verifyeventexist ('\<window name\>', '\<component name\>')
4110
 
 *
4111
 
 * \section Description
4112
 
 *
4113
 
 * verifies whether any events are present in a calendar table 
4114
 
 *
4115
 
 * \section ImplementationDetails
4116
 
 *
4117
 
 * \retval 1 on success, else 0
4118
 
 *
4119
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/calendar-view.c
4120
 
 *
4121
 
 * \section Example
4122
 
 *
4123
 
 * from ldtp import *
4124
 
 * 
4125
 
 * With respect to Evolution-Calendars
4126
 
 * 
4127
 
 * verifyeventexist ('Evolution-Calendars', 'calview') 
4128
 
 *
4129
 
 * \author Manu <manunature@rediffmail.com>
4130
 
 */
4131
 
 
4132
 
/** \page expandtablecell expandtablecell
4133
 
 * \section Syntax
4134
 
 *
4135
 
 * expandtablecell ('<window name\>', '<tree table object name\>', <row\>)
4136
 
 *
4137
 
 * \section Description
4138
 
 *
4139
 
 * Expand or contract the tree table cell on a row
4140
 
 *
4141
 
 * \retval 1 on success, LdtpExecutionError exception on failure
4142
 
 *
4143
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
4144
 
 *
4145
 
 * \section Example
4146
 
 *
4147
 
 * With respect to Evolution Mail component
4148
 
 *
4149
 
 * from ldtp import *
4150
 
 *
4151
 
 * expandtablecell ('frm*-Evolution', 'ttblMailFolderTree', 0) # In mail folder view
4152
 
 *
4153
 
 * \author 
4154
 
 */
4155
 
 
4156
 
/** \page gettreetablerowindex gettreetablerowindex
4157
 
 * \section Syntax
4158
 
 *
4159
 
 * gettreetablerowindex ('\<window name\>', '\<tree table name\>', '\<name of a table cell\>')
4160
 
 *
4161
 
 * \section Description
4162
 
 *
4163
 
 * Used to obtain the index of any table cell whose whose name is give in the last field.
4164
 
 *
4165
 
 * \section ImplementationDetails
4166
 
 *
4167
 
 * \retval index of table cell, else -1.
4168
 
 *
4169
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
4170
 
 *
4171
 
 * \section Example
4172
 
 *
4173
 
 * from ldtp import *
4174
 
 * 
4175
 
 * With respect to the tree table in Mail in Evolution
4176
 
 * 
4177
 
 * i = gettreetablerowindex ('Evolution', 'treetblMail', 'Cabinet')
4178
 
 * 
4179
 
 * here 'i' will be having the index of the Cabinet which is a table cell under tree table mail. 
4180
 
 *
4181
 
 * \author Aginesh <sraginesh@novell.com>
4182
 
 */
4183
 
 
4184
 
/** \page gettablerowindex gettablerowindex
4185
 
 * \section Syntax
4186
 
 *
4187
 
 * gettablerowindex ('\<window name\>', '\<tablename\>', '\<cellvalue\>')
4188
 
 *
4189
 
 * \section Description
4190
 
 *
4191
 
 * Returns the id of the row containing the given \<cellvalue\>
4192
 
 *
4193
 
 * \section ImplementationDetails
4194
 
 *
4195
 
 * \retval Return id of the row containing the given cell value, if it is found else return -1
4196
 
 *
4197
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/table.c
4198
 
 *
4199
 
 * \section Example
4200
 
 *
4201
 
 * In case of Evolution Calendar, to select the category form the list of categories
4202
 
 * 
4203
 
 * gettablerowindex ('dlgMeeting', 'tblCategoryList', 'Business')
4204
 
 * 
4205
 
 * The above call would return the row id of the cell containing Business. 
4206
 
 *
4207
 
 * \author Premkumar J <prem.jothimani@gmail.com>
4208
 
 */
4209
 
 
4210
 
/** \page comboselectindex comboselectindex
4211
 
 * \section Syntax
4212
 
 *
4213
 
 * comboselectindex ('\<window name\>', '\<component name\>', \<index\>)
4214
 
 *
4215
 
 * \section Description
4216
 
 *
4217
 
 * In combo box, select the list value based on index.
4218
 
 *
4219
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/combo-box.c
4220
 
 *
4221
 
 * \section Example
4222
 
 *
4223
 
 * \todo
4224
 
 *
4225
 
 * \author 
4226
 
 */
4227
 
 
4228
 
/** \page verifyvisiblebuttoncount verifyvisiblebuttoncount
4229
 
 * \section Syntax
4230
 
 *
4231
 
 * verifyvisiblebuttoncount ('<window name\>', '<toolbar name\>', <count\>)
4232
 
 *
4233
 
 * \section Description
4234
 
 *
4235
 
 * Verifies whether the toolbar button count matches with the argument count. 1 based index.
4236
 
 *
4237
 
 * \retval 1 on success, else 0
4238
 
 *
4239
 
 * \section Example
4240
 
 *
4241
 
 * With respect to gedit application toolbar
4242
 
 *
4243
 
 * from ldtp import *
4244
 
 *
4245
 
 * verifyvisiblebuttoncount ('*-gedit', 'tbar0', 12) # Gedit 2.12 default without any plugin
4246
 
 *
4247
 
 * \author J Premkumar <prem.jothimani@gmail.com>
4248
 
 */
4249
 
 
4250
 
/** \page verifybuttoncount verifybuttoncount
4251
 
 * \section Syntax
4252
 
 *
4253
 
 * verifybuttoncount ('<window name\>', '<toolbar name\>', <count\>)
4254
 
 *
4255
 
 * \section Description
4256
 
 *
4257
 
 * Verifies whether the toolbar button count matches with the argument count. 1 based index.
4258
 
 *
4259
 
 * \retval 1 on success, else 0
4260
 
 *
4261
 
 * \section Example
4262
 
 *
4263
 
 * With respect to gedit application toolbar
4264
 
 *
4265
 
 * from ldtp import *
4266
 
 *
4267
 
 * verifybuttoncount ('*-gedit', 'tbar0', 12) # Gedit 2.12 default without any plugin
4268
 
 *
4269
 
 * \author J Premkumar <prem.jothimani@gmail.com>
4270
 
 */
4271
 
 
4272
 
/** \page gettextvalue gettextvalue
4273
 
 * \section Syntax
4274
 
 *
4275
 
 * gettextvalue ('\<window name\>', '\<component name\>', \<startoffset\>, \<endoffset\>)
4276
 
 *
4277
 
 * \section Description
4278
 
 *
4279
 
 * returns the text within the given range in the component given by the component name. \<startoffset\> and \<endoffset\> are optional. If they are ommited, the entire text is returned. 
4280
 
 *
4281
 
 * \retval text data of string type on success, LdtpExecutionError exception on failure
4282
 
 *
4283
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
4284
 
 *
4285
 
 * \section Example
4286
 
 *
4287
 
 * With respect to gnome search tool structure
4288
 
 * 
4289
 
 * gettextvalue ('SearchforFiles', 'txtNameContainsEntry')
4290
 
 * 
4291
 
 * The above statement will return the text present in 'txtNameContainsEntry' field.
4292
 
 * 
4293
 
 * gettextvalue ('SearchforFiles', 'txtNameContainsEntry', 5)
4294
 
 * 
4295
 
 * The above statement will return the text present in 'txtNameContainsEntry' field starting from the fifth character.
4296
 
 * 
4297
 
 * gettextvalue ('SearchforFiles', 'txtNameContainsEntry', 5, 10)
4298
 
 * 
4299
 
 * The above statement will return the text present in 'txtNameContainsEntry' field starting from the fifth character
4300
 
 * 
4301
 
 * till the tenth character. 
4302
 
 *
4303
 
 * \author Premkumar J <prem.jothimani@gmail.com>
4304
 
 */
4305
 
 
4306
 
/** \page getcellvalue getcellvalue
4307
 
 * \section Syntax
4308
 
 *
4309
 
 * getcellvalue ('\<window name\>', '\<component name\>', '\<row\>', '\<column\>')
4310
 
 *
4311
 
 * \section Description
4312
 
 *
4313
 
 * returns the text in a cell at given row and column of a tree table 
4314
 
 *
4315
 
 * \retval cell value of type string on success, else LdtpExecutionError exception
4316
 
 *
4317
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/table.c
4318
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
4319
 
 *
4320
 
 * \section Example
4321
 
 *
4322
 
 * With respect to Evolution Messages tree table
4323
 
 * 
4324
 
 * gettextvalue ('Evolution-Mail', 'treetblMails', 2, 4)
4325
 
 * 
4326
 
 * This will return the subject of 3rd message in the message list. 
4327
 
 *
4328
 
 * \author Khasim Shaheed <khasim.shaheed@gmail.com>
4329
 
 * \author Premkumar J <prem.jothimani@gmail.com>
4330
 
 */
4331
 
 
4332
 
/** \page capturetofile capturetofile
4333
 
 * \section Syntax
4334
 
 *
4335
 
 * capturetofile ('\<window name\>', '\<combo box name\>'[, '\<file name\>'])
4336
 
 *
4337
 
 * \section Description
4338
 
 *
4339
 
 * Capture the list of contents of a combox box to a file. If file name argument is None, then by default the list contents are written to comboboxitem.lst file of current working directory of LDTP engine.
4340
 
 *
4341
 
 * \retval 1 on success, LdtpExecutionError on failure
4342
 
 *
4343
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/combo-box.c
4344
 
 *
4345
 
 * \section Example
4346
 
 *
4347
 
 * With respect to Find dialog of gedit application
4348
 
 *
4349
 
 * from ldtp import *
4350
 
 *
4351
 
 * # Without specifiying the filename
4352
 
 *
4353
 
 * capturetofile ('dlgFind', 'cboSearchfor')
4354
 
 *
4355
 
 * # With specifiying the filename
4356
 
 *
4357
 
 * capturetofile ('dlgFind', 'cboSearchfor', '/tmp/comboboxlistitem.txt') # Note relative path won't work !!!
4358
 
 *
4359
 
 * \author Premkumar J <prem.jothimani@gmail.com>
4360
 
 */
4361
 
 
4362
 
/** \page gettextproperty gettextproperty
4363
 
 * \section Syntax
4364
 
 *
4365
 
 * gettextproperty ('<window name\>', '<text object name\>'[, <start position\>[, <end position\>]])
4366
 
 *
4367
 
 * \section Description
4368
 
 *
4369
 
 * Get the text attributes
4370
 
 *
4371
 
 * \retval text attributes of type string on success, LdtpExecutionError exception on failure
4372
 
 *
4373
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
4374
 
 *
4375
 
 * \section Example
4376
 
 *
4377
 
 * \todo
4378
 
 *
4379
 
 * \author Premkumar J <prem.jothimani@gmail.com>
4380
 
 */
4381
 
 
4382
 
/** \page comparetextproperty comparetextproperty
4383
 
 * \section Syntax
4384
 
 *
4385
 
 * comparetextproperty ('<window name\>', '<text object name\>', '<text property\>'[, <start position\>[, <end position\>]])
4386
 
 *
4387
 
 * \section Description
4388
 
 *
4389
 
 * Compares the text attribute properties
4390
 
 *
4391
 
 * Default value of start and end positions are 0 and length of the string.
4392
 
 *
4393
 
 * \retval 1 on success, 0 on failure
4394
 
 *
4395
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
4396
 
 *
4397
 
 * \section Example
4398
 
 *
4399
 
 * \todo
4400
 
 *
4401
 
 * \author Premkumar J <prem.jothimani@gmail.com>
4402
 
 */
4403
 
 
4404
 
/** \page containstextproperty containstextproperty
4405
 
 * \section Syntax
4406
 
 *
4407
 
 * containstextproperty ('<window name\>', '<text object name\>', '<text property\>'[, <start position\>[, <end position\>]])
4408
 
 *
4409
 
 * \section Description
4410
 
 *
4411
 
 * Checks for one or more text attribute properties
4412
 
 *
4413
 
 * Default value of start and end positions are 0 and length of the string.
4414
 
 *
4415
 
 * \retval 1 on success, 0 on failure
4416
 
 *
4417
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/text.c
4418
 
 *
4419
 
 * \section Example
4420
 
 *
4421
 
 * \todo
4422
 
 *
4423
 
 * \author Premkumar J <prem.jothimani@gmail.com>
4424
 
 */
4425
 
 
4426
 
/** \page selectcalendardate selectcalendardate
4427
 
 * \section Syntax
4428
 
 *
4429
 
 * selectcalendardate ('\<window name\>', '\<calendar object name\>', \<day\>, \<month\>, \<year\>)
4430
 
 *
4431
 
 * \section Description
4432
 
 *
4433
 
 * 
4434
 
 *
4435
 
 * \retval 1 on success, LdtpExecutionError exception on failure
4436
 
 *
4437
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/calendar.c
4438
 
 *
4439
 
 * \section Example
4440
 
 *
4441
 
 * \todo
4442
 
 *
4443
 
 * \author Premkumar J <prem.jothimani@gmail.com>
4444
 
 */
4445
 
 
4446
 
/** \page remap remap
4447
 
 * \section Syntax
4448
 
 *
4449
 
 * remap ('\<window name\>'[, '\<component name\>'])
4450
 
 * 
4451
 
 * undoremap ('\<application-name\>', '\<dialog name\>') 
4452
 
 *
4453
 
 * \section Description
4454
 
 *
4455
 
 * We can handle dynamically created widgets (meaning widgets created at run time) using this remap function. Calling remap will generate appmap for the given dialog at run time and update the hash table. Then we can access the new widgets. But please make sure to call undoremap() once the required functions are performed so that the hash table will be reverted back to its original state. The reason for having undoremap() is that subsequent calls to remap() might corrupt the hash table containg the appmap entries.
4456
 
 * 
4457
 
 * Please not that the <application-name> should be same as the one given as the commmand-line argument for appmap generation. 
4458
 
 *
4459
 
 * \section ImplementationDetails
4460
 
 *
4461
 
 * It uses the same logic that appmap module uses to generate appmap. Please refer to the following link for the source code of the remap functionality
4462
 
 *
4463
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/remap.c
4464
 
 *
4465
 
 * \section Example
4466
 
 * 
4467
 
 * remap ('dlggeditPreferences') # Remaps the complete gedit preferences dialog
4468
 
 * 
4469
 
 * remap ('dlggeditPreferences', 'ptabView') # Remaps all the controls under page tab with the name View of gedit Preferences dialog.
4470
 
 * 
4471
 
 * . .
4472
 
 * 
4473
 
 * undoremap ('evolution', 'dlgAppointment-Nosummary') 
4474
 
 *
4475
 
 * \author Premkumar J <prem.jothimani@gmail.com>
4476
 
 */
4477
 
 
4478
 
/** \page getwindowlist getwindowlist
4479
 
 * \section Syntax
4480
 
 *
4481
 
 * getwindowlist ()
4482
 
 *
4483
 
 * \section Description
4484
 
 *
4485
 
 * Gets all the window name, that are currently opened. If none of the windows are opened, then LdtpExecutionError will be thrown.
4486
 
 *
4487
 
 * \retval list of window names will be returned on success, LdtpExecutionError exception on failure
4488
 
 *
4489
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
4490
 
 *
4491
 
 * \section Example
4492
 
 *
4493
 
 * from ldtp import *
4494
 
 *
4495
 
 * getwindowlist ()
4496
 
 *
4497
 
 * \author Premkumar J <prem.jothimani@gmail.com>
4498
 
 */
4499
 
 
4500
 
/** \page getwindowsize getwindowsize
4501
 
 * \section Syntax
4502
 
 *
4503
 
 * getwindowsize ('\<window name\>')
4504
 
 *
4505
 
 * \section Description
4506
 
 *
4507
 
 * Get the window size, of the given window name. If window does not exist, then LdtpExecutionError will be thrown.
4508
 
 *
4509
 
 * \retval x, y, width, height as a list and as int type will be returned on success, LdtpExecutionError exception on failure
4510
 
 *
4511
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/ldtp-gui.c
4512
 
 *
4513
 
 * \section Example
4514
 
 *
4515
 
 * launchapp ('gedit')
4516
 
 *
4517
 
 * getwindowsize ('*-gedit')
4518
 
 *
4519
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
4520
 
 */
4521
 
 
4522
 
/** \page getobjectsize getobjectsize
4523
 
 * \section Syntax
4524
 
 *
4525
 
 * getobjectsize ('\<window name\>'[, '\<object name\>'])
4526
 
 *
4527
 
 * \section Description
4528
 
 *
4529
 
 * Get the object size, of the given window. If object does not exist, then LdtpExecutionError will be thrown.
4530
 
 *
4531
 
 * \retval x, y, width, height as a list and as int type will be returned on success, LdtpExecutionError exception on failure
4532
 
 *
4533
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/ldtp-gui.c
4534
 
 *
4535
 
 * \section Example
4536
 
 *
4537
 
 * launchapp ('gedit')
4538
 
 *
4539
 
 * getobjectsize ('*-gedit', 'btnFind')
4540
 
 *
4541
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
4542
 
 */
4543
 
 
4544
 
/** \page getapplist getapplist
4545
 
 * \section Syntax
4546
 
 *
4547
 
 * getapplist ()
4548
 
 *
4549
 
 * \section Description
4550
 
 *
4551
 
 * Will return all the accessibility application window title that are currently opened
4552
 
 *
4553
 
 * \retval list of window names will be returned on success, LdtpExecutionError exception on failure
4554
 
 *
4555
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
4556
 
 *
4557
 
 * \section Example
4558
 
 *
4559
 
 * from ldtp import *
4560
 
 *
4561
 
 * getapplist () # Will return all the accessibility application window title that are currently opened
4562
 
 *
4563
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
4564
 
 */
4565
 
 
4566
 
/** \page getallstates getallstates
4567
 
 * \section Syntax
4568
 
 *
4569
 
 * getallstates ('\<window name\>'[, '\<component name\>'])
4570
 
 *
4571
 
 * \section Description
4572
 
 *
4573
 
 * Will return all the accessibility states of given object information
4574
 
 *
4575
 
 * \retval list of states will be returned on success, LdtpExecutionError exception on failure
4576
 
 *
4577
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
4578
 
 *
4579
 
 * \section Example
4580
 
 *
4581
 
 * from ldtp import *
4582
 
 *
4583
 
 * getallstates () # Will return all the accessibility states of given
4584
 
 * object information
4585
 
 * Compare all the states based on your requirement, say for example,
4586
 
 * if interested in checking for VISIBLE state, then:
4587
 
 * 
4588
 
 * states = getallstates ('*-gedit', 'btnCopy')
4589
 
 * if state.VISIBLE in states:
4590
 
 *     print 'Object is visible'
4591
 
 *
4592
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
4593
 
 */
4594
 
 
4595
 
/** \page getchild getchild
4596
 
 * \section Syntax
4597
 
 *
4598
 
 * getchild ('\<window name\>'<[, '\<component name\>'], [ '\<role\>']>)
4599
 
 *
4600
 
 * \section Description
4601
 
 *
4602
 
 * Gets the list of object available in the window, which matches
4603
 
 * component name or role name or both.
4604
 
 *
4605
 
 * \retval List of objects on success, LdtpExecutionError exception on failure
4606
 
 *
4607
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
4608
 
 *
4609
 
 * \section Example
4610
 
 *
4611
 
 * With respect to Find object of gedit application
4612
 
 *
4613
 
 * from ldtp import *
4614
 
 *
4615
 
 * getchild ('*-gedit', 'Find')
4616
 
 *
4617
 
 * getchild ('*-gedit', role = 'push button')
4618
 
 *
4619
 
 * getchild ('*-gedit', 'Find', role = 'push button')
4620
 
 *
4621
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
4622
 
 */
4623
 
 
4624
 
/** \page getobjectlist getobjectlist
4625
 
 * \section Syntax
4626
 
 *
4627
 
 * getobjectlist ('\<window name\>')
4628
 
 *
4629
 
 * \section Description
4630
 
 *
4631
 
 * Gets the list of object available in the window (if window exist, else exception will be thrown)
4632
 
 *
4633
 
 * \retval List of objects on success, LdtpExecutionError exception on failure
4634
 
 *
4635
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
4636
 
 *
4637
 
 * \section Example
4638
 
 *
4639
 
 * With respect to Find dialog of gedit application
4640
 
 *
4641
 
 * from ldtp import *
4642
 
 *
4643
 
 * getobjectlist ('dlgFind')
4644
 
 *
4645
 
 * \author Premkumar J <prem.jothimani@gmail.com>
4646
 
 */
4647
 
 
4648
 
/** \page getobjectinfo getobjectinfo
4649
 
 * \section Syntax
4650
 
 *
4651
 
 * getobjectinfo ('\<window name\>', '\<object name\>')
4652
 
 *
4653
 
 * \section Description
4654
 
 *
4655
 
 * Gets the list of object information lik class, parent, label, label_by, child_index
4656
 
 *
4657
 
 * \retval list of object properies (example, class, parent, label, label_by, child_index) on success, LdtpExecutionError exception on failure
4658
 
 *
4659
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
4660
 
 *
4661
 
 * \section Example
4662
 
 *
4663
 
 * With respect to gedit Find dialog
4664
 
 *
4665
 
 * from ldtp import *
4666
 
 *
4667
 
 * getobjectinfo ('dlgFind', 'btnFind')
4668
 
 *
4669
 
 * \author 
4670
 
 */
4671
 
 
4672
 
/** \page getobjectproperty getobjectproperty
4673
 
 * \section Syntax
4674
 
 *
4675
 
 * getobjectproperty ('<window name\>', '<object name\>', '\<object property\>')
4676
 
 *
4677
 
 * \section Description
4678
 
 *
4679
 
 * Get the object property if available, else exception will be thrown
4680
 
 *
4681
 
 * \retval object property string on success, LdtpExecutionError exception on failure
4682
 
 *
4683
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
4684
 
 *
4685
 
 * \section Example
4686
 
 *
4687
 
 * With respect to find dialog of gedit application
4688
 
 *
4689
 
 * from ldtp import *
4690
 
 *
4691
 
 * getobjectproperty ('dlgFind', 'btnFind', 'label') # Returns '_Find' string in US.English locale
4692
 
 *
4693
 
 * \author Premkumar J <prem.jothimani@gmail.com>
4694
 
 */
4695
 
 
4696
 
/** \page doubleclickrow doubleclickrow
4697
 
 * \section Syntax
4698
 
 *
4699
 
 * doubleclickrow ('\<window name\>', '\<table name\>', '\<value of row in first column\>')
4700
 
 *
4701
 
 * \section Description
4702
 
 *
4703
 
 * Double clicks the row in table whose first column's (0th column) value is same as the contents of the third argument in the function call.
4704
 
 *
4705
 
 * \retval 1 on success, else 0.
4706
 
 *
4707
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
4708
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/table.c
4709
 
 *
4710
 
 * \section Example
4711
 
 *
4712
 
 * \todo
4713
 
 *
4714
 
 * \author Premkumar J <prem.jothimani@gmail.com>
4715
 
 */
4716
 
 
4717
 
/** \page doubleclickrowindex doubleclickrowindex
4718
 
 * \section Syntax
4719
 
 *
4720
 
 * doubleclickrowindex ('\<window name\>', '\<table name\>', \<row index\>)
4721
 
 *
4722
 
 * \section Description
4723
 
 *
4724
 
 * Double clicks the row in table whose first column's (0th column) value is same as the contents of the third argument in the function call.
4725
 
 *
4726
 
 * \retval 1 on success, else 0.
4727
 
 *
4728
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
4729
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/table.c
4730
 
 *
4731
 
 * \section Example
4732
 
 *
4733
 
 * \todo
4734
 
 *
4735
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
4736
 
 */
4737
 
 
4738
 
/** \page singleclickrow singleclickrow
4739
 
 * \section Syntax
4740
 
 *
4741
 
 * singleclickrow ('\<window name\>', '\<table name\>', '\<value of row in first column\>')
4742
 
 *
4743
 
 * \section Description
4744
 
 *
4745
 
 * Single clicks the row in table whose first column's (0th column) value is same as the contents of the third argument in the function call.
4746
 
 *
4747
 
 * \retval 1 on success, else 0.
4748
 
 *
4749
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
4750
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/table.c
4751
 
 *
4752
 
 * \section Example
4753
 
 *
4754
 
 * \todo
4755
 
 *
4756
 
 * \author Premkumar J <prem.jothimani@gmail.com>
4757
 
 */
4758
 
 
4759
 
/** \page doubleclick doubleclick
4760
 
 * \section Syntax
4761
 
 *
4762
 
 * doubleclick ('\<window name\>', '\<component name\>')
4763
 
 *
4764
 
 * \section Description
4765
 
 *
4766
 
 * Double clicks the row in table whose first column's (0th column) value is same as the contents of the third argument in the function call.
4767
 
 *
4768
 
 * \retval 1 on success, else 0
4769
 
 *
4770
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/tree-table.c
4771
 
 *
4772
 
 * \section Example
4773
 
 *
4774
 
 * \todo
4775
 
 *
4776
 
 * \author Premkumar J <prem.jothimani@gmail.com>
4777
 
 */
4778
 
 
4779
 
/** \page listsubmenus listsubmenus
4780
 
 * \section Syntax
4781
 
 *
4782
 
 * listsubmenus ('window name\>', 'menu name\>')
4783
 
 *
4784
 
 * \section Description
4785
 
 *
4786
 
 * Get the list of sub menu item, in a menu in a ; seperated list
4787
 
 *
4788
 
 * \retval ';' seperated string on success, LdtpExecutionError exception on failure
4789
 
 *
4790
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/menu-item.c
4791
 
 *
4792
 
 * \section Example
4793
 
 *
4794
 
 * With respect to gedit application, File menu
4795
 
 *
4796
 
 * from ldtp import *
4797
 
 *
4798
 
 * listsubmenus ('*-gedit', 'mnuFile') # all the submenus of File menu in ';' seperated string
4799
 
 *
4800
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
4801
 
 */
4802
 
 
4803
 
/** \page invokemenu invokemenu
4804
 
 * \section Syntax
4805
 
 *
4806
 
 * invokemenu ('window name\>', 'object name\>')
4807
 
 *
4808
 
 * \section Description
4809
 
 *
4810
 
 * Invokes the menu in an embedded component (accessible) type
4811
 
 *
4812
 
 * \retval 1 on success, LdtpExecutionError exception on failure
4813
 
 *
4814
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/embedded-component.c
4815
 
 *
4816
 
 * \section Example
4817
 
 *
4818
 
 * With respect to gedit application, File menu
4819
 
 *
4820
 
 * from ldtp import *
4821
 
 *
4822
 
 * invokemenu ('frmBottomExpandedEdgePanel', 'Volume Control')
4823
 
 *
4824
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
4825
 
 */
4826
 
 
4827
 
/** \page verifyscrollbar verifyscrollbar
4828
 
 * \section Syntax
4829
 
 *
4830
 
 * verifyscrollbar ('<window name\>', '<scroll bar name\>')
4831
 
 *
4832
 
 * \section Description
4833
 
 *
4834
 
 * Checks whether the given object is scrollbar or not, also we can check whether scroll bar object is available or not
4835
 
 *
4836
 
 * \retval 1 on success, else 0
4837
 
 *
4838
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/scroll-bar.c
4839
 
 *
4840
 
 * \section Example
4841
 
 *
4842
 
 * With respect to gedit application
4843
 
 *
4844
 
 * from ldtp import *
4845
 
 *
4846
 
 * verifyscrollbar ('*-gedit', 'scbr0') # assuming that the file currently opened content is more than one page, else the scrollbar object will not be created by accessibility interface
4847
 
 *
4848
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
4849
 
 */
4850
 
 
4851
 
/** \page verifyscrollbarhorizontal verifyscrollbarhorizontal
4852
 
 * \section Syntax
4853
 
 *
4854
 
 * verifyscrollbarhorizontal ('<window name\>', '<scroll bar name\>')
4855
 
 *
4856
 
 * \section Description
4857
 
 *
4858
 
 * Checks whether the given object is horizontal scrollbar or not
4859
 
 *
4860
 
 * \retval 1 on success, else 0
4861
 
 *
4862
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/scroll-bar.c
4863
 
 *
4864
 
 * \section Example
4865
 
 *
4866
 
 * With respect to gedit application
4867
 
 *
4868
 
 * from ldtp import *
4869
 
 
4870
 
 * verifyscrollbarhorizontal ('*-gedit', 'scbr0') # assuming that you have more columns than the actual visible area, else the scrollbar object will not be created by accessibility interface
4871
 
 *
4872
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
4873
 
 */
4874
 
 
4875
 
/** \page verifyscrollbarvertical verifyscrollbarvertical
4876
 
 * \section Syntax
4877
 
 *
4878
 
 * verifyscrollbarvertical ('<window name\>', '<scroll bar name\>')
4879
 
 *
4880
 
 * \section Description
4881
 
 *
4882
 
 * Checks whether the given object is vertical scrollbar or not
4883
 
 *
4884
 
 * \retval 1 on success, else 0
4885
 
 *
4886
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/scroll-bar.c
4887
 
 *
4888
 
 * \section Example
4889
 
 *
4890
 
 * With respect to gedit application
4891
 
 *
4892
 
 * from ldtp import *
4893
 
 
4894
 
 * verifyscrollbarhorizontal ('*-gedit', 'scbr0') # assuming that you have more columns than the actual visible area, else the scrollbar object will not be created by accessibility interface
4895
 
 *
4896
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
4897
 
 */
4898
 
 
4899
 
/** \page verifyslider verifyslider
4900
 
 * \section Syntax
4901
 
 *
4902
 
 * verifyslider ('<window name\>', '<slider name\>')
4903
 
 *
4904
 
 * \section Description
4905
 
 *
4906
 
 * 
4907
 
 *
4908
 
 * \retval 1 on success, else 0
4909
 
 *
4910
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/slider.c
4911
 
 *
4912
 
 * \section Example
4913
 
 *
4914
 
 * \todo
4915
 
 *
4916
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
4917
 
 */
4918
 
 
4919
 
/** \page verifysliderhorizontal verifysliderhorizontal
4920
 
 * \section Syntax
4921
 
 *
4922
 
 * verifysliderhorizontal ('<window name\>', '<slider name\>')
4923
 
 *
4924
 
 * \section Description
4925
 
 *
4926
 
 * 
4927
 
 *
4928
 
 * \retval 1 on success, else 0
4929
 
 *
4930
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/slider.c
4931
 
 *
4932
 
 * \section Example
4933
 
 *
4934
 
 * \todo
4935
 
 *
4936
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
4937
 
 */
4938
 
 
4939
 
/** \page verifyslidervertical verifyslidervertical
4940
 
 * \section Syntax
4941
 
 *
4942
 
 * verifyslidervertical ('<window name\>', '<slider name\>')
4943
 
 *
4944
 
 * \section Description
4945
 
 *
4946
 
 * 
4947
 
 *
4948
 
 * \retval 1 on success, else 0
4949
 
 *
4950
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/slider.c
4951
 
 *
4952
 
 * \section Example
4953
 
 *
4954
 
 * \todo
4955
 
 *
4956
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
4957
 
 */
4958
 
 
4959
 
/** \page onwindowcreate onwindowcreate
4960
 
 * \section Syntax
4961
 
 *
4962
 
 * onwindowcreate ('<window title\>', '<callback function\>'[,
4963
 
 * <arguments to callback function\>])
4964
 
 *
4965
 
 * \section Description
4966
 
 *
4967
 
 * Watch, window create event, with the given title and call the respective callback function. Window title supports regular expression too.
4968
 
 *
4969
 
 * \retval 1 on success, else LdtpExecutionError exception
4970
 
 *
4971
 
 * Refer:
4972
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
4973
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/ldtp-gui.c
4974
 
 *
4975
 
 * \section Example
4976
 
 *
4977
 
 * With respect to gedit application, replace dialog
4978
 
 *
4979
 
 * <pre>
4980
 
 *
4981
 
 * from ldtp import *
4982
 
 * import threading
4983
 
 * 
4984
 
 * callbackRunning = threading.Event()
4985
 
 * callbackRunning.clear()
4986
 
 * callbackState = threading.Event()
4987
 
 * callbackState.clear()
4988
 
 * 
4989
 
 * def cb():
4990
 
 *      callbackState.set()
4991
 
 *      waittillguiexist('dlgReplace')
4992
 
 *      click('dlgReplace', 'btnClose')
4993
 
 *      callbackState.clear()
4994
 
 *      callbackRunning.set()
4995
 
 *      print 'callbackend'
4996
 
 *
4997
 
 * def cbwithvarargs(*args):
4998
 
 *      for arg in args:
4999
 
 *              print arg
5000
 
 *      print 'callbackend'
5001
 
 *
5002
 
 * onwindowcreate('Replace', cb)
5003
 
 * onwindowcreate('dlgFind', cbwithvarargs, 'test', 'var', 'args')
5004
 
 *
5005
 
 * click('*gedit', 'btnReplace')
5006
 
 * click('*gedit', 'btnFind')
5007
 
 *
5008
 
 * waittillguiexist('dlgFind')
5009
 
 * click('dlgFind', 'btnClose')
5010
 
 *
5011
 
 * if callbackState.isSet():
5012
 
 *      print 'Waiting for callback to complete'
5013
 
 *      callbackRunning.wait()
5014
 
 *      print 'callbackset'
5015
 
 * print 'test end'
5016
 
 *
5017
 
 * </pre>
5018
 
 *
5019
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5020
 
 */
5021
 
 
5022
 
/** \page removecallback removecallback
5023
 
 * \section Syntax
5024
 
 *
5025
 
 * removecallback ('<window title\>')
5026
 
 *
5027
 
 * \section Description
5028
 
 *
5029
 
 * Remove the callback function that was registered with onwindowcreate
5030
 
 *
5031
 
 * \retval 1 on success, else LdtpExecutionError exception
5032
 
 *
5033
 
 * Refer:
5034
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
5035
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/ldtp-gui.c
5036
 
 *
5037
 
 * \section Example
5038
 
 *
5039
 
 * With respect to gedit application, replace dialog
5040
 
 *
5041
 
 * <pre>
5042
 
 *
5043
 
 * from ldtp import *
5044
 
 *
5045
 
 * import threading
5046
 
 *
5047
 
 * 
5048
 
 * callbackRunning = threading.Event ()
5049
 
 *
5050
 
 * callbackRunning.clear ()
5051
 
 *
5052
 
 * callbackState = threading.Event ()
5053
 
 *
5054
 
 * callbackState.clear ()
5055
 
 *
5056
 
 * 
5057
 
 * def cb ():
5058
 
 *
5059
 
 *      callbackState.set ()
5060
 
 *
5061
 
 *      waittillguiexist ('dlgReplace')
5062
 
 *
5063
 
 *      click ('dlgReplace', 'btnClose')
5064
 
 *
5065
 
 *      callbackState.clear ()
5066
 
 *
5067
 
 *      callbackRunning.set ()
5068
 
 *
5069
 
 *      print 'callbackend'
5070
 
 *
5071
 
 * 
5072
 
 * onwindowcreate ('Replace', cb)
5073
 
 *
5074
 
 * click ('*gedit', 'btnReplace')
5075
 
 *
5076
 
 * click ('*gedit', 'btnFind')
5077
 
 *
5078
 
 * waittillguiexist ('dlgFind')
5079
 
 *
5080
 
 * click ('dlgFind', 'btnClose')
5081
 
 *
5082
 
 * if callbackState.isSet ():
5083
 
 *
5084
 
 *      print 'Waiting for callback to complete'
5085
 
 *
5086
 
 *      callbackRunning.wait ()
5087
 
 *
5088
 
 *      print 'callbackset'
5089
 
 *
5090
 
 * print 'test end'
5091
 
 *
5092
 
 * removecallback ('Replace')
5093
 
 *
5094
 
 * </pre>
5095
 
 *
5096
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5097
 
 */
5098
 
 
5099
 
/** \page doesmenuitemexist doesmenuitemexist
5100
 
 * \section Syntax
5101
 
 *
5102
 
 * doesmenuitemexist ('\<window name\>', '\<menu hierarchy\>') 
5103
 
 *
5104
 
 * \section Description
5105
 
 *
5106
 
 * checks if the specified menuitem specified in the menu hierarchy is present or not
5107
 
 *
5108
 
 * \section ImplementationDetails
5109
 
 *
5110
 
 * \retval 1 if the menuitem is present, else 0
5111
 
 *
5112
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/menu-item.c
5113
 
 *
5114
 
 * \section Example
5115
 
 *
5116
 
 * With respect to gedit menu structure
5117
 
 * 
5118
 
 * doesselectmenuitem ('gedit', 'mnuFile;mnuNew')
5119
 
 * 
5120
 
 * this function is required mainly to check those menuitems which will not be present always. An example of this kind of a menuitem is the close tab menu item under menu file in firefox web browser. 
5121
 
 *
5122
 
 * \author J Premkumar <prem.jothimani@gmail.com>
5123
 
 */
5124
 
 
5125
 
/** \page startlog startlog
5126
 
 * \section Syntax
5127
 
 * 
5128
 
 * startlog ('\<log file name\>', [[0 or 1], ['\<screenshot directory\>']])
5129
 
 * 
5130
 
 * second argument is optional and 1 is default value
5131
 
 * 
5132
 
 * 0 - Append log to an existing file
5133
 
 * 
5134
 
 * 1 - Write log to a new file. If file already exist, then erase
5135
 
 * existing file content and start log
5136
 
 * 
5137
 
 * Screenshot files has to be placed in screenshot directory
5138
 
 * 
5139
 
 * \section Description
5140
 
 * 
5141
 
 * Start logging on the specified file. Default log level set is logging.WARNING. Though this can be changed with setloglevel LDTP API.
5142
 
 * 
5143
 
 * \section ImplementationDetails
5144
 
 * Log file will be created if log file is not present in any case. If second argument is 1, then existing file content will be erased. If second argument is 0, then new logs will be append to existing log.
5145
 
 * 
5146
 
 * \retval 1 on Success and 0 on error
5147
 
 * 
5148
 
 * \section Example
5149
 
 * 
5150
 
 * If we want to overwrite existing log file or create new log file:
5151
 
 * 
5152
 
 * startlog ('evolution.xml', 1)
5153
 
 * 
5154
 
 * If we want to append existing log file or create new log file:
5155
 
 * 
5156
 
 * startlog ('evolution.xml', 0)
5157
 
 * 
5158
 
 * or 
5159
 
 * 
5160
 
 * startlog ('evolution.xml')
5161
 
 * 
5162
 
 * or 
5163
 
 * 
5164
 
 * startlog ('~/evolution.xml', screenshotdir = '~/screenshot')
5165
 
 * evolution.xml log file will ge generated in home directory of
5166
 
 * current user and the screenshot files will be placed screenshot
5167
 
 * folder of current user's home directory.
5168
 
 * 
5169
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5170
 
 */
5171
 
 
5172
 
/** \page stoplog stoplog
5173
 
 * \section Syntax
5174
 
 * 
5175
 
 * stoplog ()
5176
 
 * 
5177
 
 * \section Description
5178
 
 * 
5179
 
 * Stop logging
5180
 
 * 
5181
 
 * \section ImplementationDetails
5182
 
 * If a log file has been previously opened for logging, that file pointer will be closed. So that the new logging will not be appened to the log file.
5183
 
 * 
5184
 
 * \section Example
5185
 
 * 
5186
 
 * stoplog ()
5187
 
 * 
5188
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5189
 
 */
5190
 
 
5191
 
 
5192
 
/** \page startldtplog startldtplog
5193
 
 * \section Syntax
5194
 
 * 
5195
 
 * startldtplog ('\<log file name\>', [0 or 1])
5196
 
 * 
5197
 
 * second argument is optional and 1 is default value
5198
 
 * 
5199
 
 * 0 - Append ldtplog to an existing file
5200
 
 * 
5201
 
 * 1 - Write ldtp log to a new file. If file already exist, then erase existing file content and start ldtp log
5202
 
 * 
5203
 
 * \section Description
5204
 
 * 
5205
 
 * Start ldtp logging on the specified file
5206
 
 * 
5207
 
 * \section ImplementationDetails
5208
 
 * Log file will be created if log file is not present in any case. If second argument is 1, then existing file content will be erased. If second argument is 0, then new logs will be append to existing log.
5209
 
 * 
5210
 
 * \retval 1 on Success and 0 on error
5211
 
 * 
5212
 
 * \section Example
5213
 
 * 
5214
 
 * If we want to overwrite existing log file or create new log file:
5215
 
 * 
5216
 
 * startldtplog ('evolution.xml', 1)
5217
 
 * 
5218
 
 * If we want to append existing log file or create new log file:
5219
 
 * 
5220
 
 * startldtplog ('evolution.xml', 0)
5221
 
 * 
5222
 
 * or 
5223
 
 * 
5224
 
 * startldtplog ('evolution.xml')
5225
 
 * 
5226
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5227
 
 */
5228
 
 
5229
 
/** \page stopldtplog stopldtplog
5230
 
 * \section Syntax
5231
 
 * 
5232
 
 * stopldtplog ()
5233
 
 * 
5234
 
 * \section Description
5235
 
 * 
5236
 
 * Stop ldtplogging
5237
 
 * 
5238
 
 * \section ImplementationDetails
5239
 
 * If a log file has been previously opened for logging, that file pointer will be closed. So that the new logging will not be appened to the log file.
5240
 
 * 
5241
 
 * \section Example
5242
 
 * 
5243
 
 * stopldtplog ()
5244
 
 * 
5245
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5246
 
 */
5247
 
 
5248
 
/** \page imagecapture imagecapture
5249
 
 * \section Syntax
5250
 
 *
5251
 
 * imagecapture ([\<window name\>, [\<output file\>, (opt)\<width-x\>, (opt)\<height-y\>, (opt)x, (opt)y]])
5252
 
 *
5253
 
 * \section Description
5254
 
 *
5255
 
 * Capture snap-shot of the window. Where startx & starty are offset. If window name is not provided, then the complete X screen is captured. If output file name is not provided, then a temporary file will be created and the file name will be returned. File has to be explicitly deleted by the user.
5256
 
 *
5257
 
 * \section ImplementationDetails
5258
 
 *
5259
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5260
 
 *
5261
 
 * \section Example
5262
 
 *
5263
 
 * from ldtputils import *
5264
 
 *
5265
 
 * imagecapture ('Terminal', 'out.png') # out.jpg will be created in current directory. Give absolute path to save it in some other directory.
5266
 
 *
5267
 
 * imagecapture () # Captures the complete X screen and saves in a temp file and returns the file name.
5268
 
 *
5269
 
 * \note Window title name is case sensitive
5270
 
 *
5271
 
 * \section Dependency
5272
 
 *
5273
 
 * Digwin binary - http://sourceforge.net/projects/ltfx If a specific window has to be captured, then digwin is used to get the window id.
5274
 
 *
5275
 
 * Import utility of ImageMagick - http://www.imagemagick.org/script/import.php # Mandatory dependency, if you want to use this function.
5276
 
 *
5277
 
 * \author Nagashree <mnagashree@novell.com>
5278
 
 */
5279
 
 
5280
 
/** \page imagecompare imagecompare
5281
 
 * \section Syntax
5282
 
 *
5283
 
 * imagecompare (imgfile1, imgfile2)
5284
 
 *
5285
 
 * \section Description
5286
 
 *
5287
 
 * Compares two images and returns difference of them in percentage. If PIL package is not installed, LdtpExecutionError exception will be thrown.
5288
 
 *
5289
 
 * \retval difference in percentage on successful image comaprison, else LdtpExecutionError exception
5290
 
 *
5291
 
 * Note: Script designer can decide the pass / fail criteria based on the diff percentage.
5292
 
 *
5293
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5294
 
 *
5295
 
 * \section Example
5296
 
 *
5297
 
 * from ldtputils import *
5298
 
 *
5299
 
 * imagecompare ('in.jpg', 'out.jpg') # Assuming that in.jpg and out.jpg are in current directory. File path should be absolute path.
5300
 
 *
5301
 
 * \section Dependency
5302
 
 *
5303
 
 * Python Imaging Library - http://www.pythonware.com/products/pil/
5304
 
 *
5305
 
 * \author Shankar Ganesh <shagan.glare@gmail.com>
5306
 
 * \author Veerapuram Varadhan <v.varadhan@gmail.com>
5307
 
 */
5308
 
 
5309
 
/** \page blackoutregion blackoutregion
5310
 
 * \section Syntax
5311
 
 *
5312
 
 * blackoutregion (infile, outfile, topx, topy, botx, boty)
5313
 
 *
5314
 
 * \section Description
5315
 
 *
5316
 
 * Blacks out the region in the image given by
5317
 
 * 
5318
 
 * top-coords - topx,topy bottom-coords - botx,boty
5319
 
 * 
5320
 
 * of the region 
5321
 
 *
5322
 
 * \section ImplementationDetails
5323
 
 *
5324
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5325
 
 *
5326
 
 * \section Example
5327
 
 *
5328
 
 * blackoutregion ('in.jpg','out.jpg',100,100,200,200)
5329
 
 *
5330
 
 * \section Dependency
5331
 
 *
5332
 
 * Python Imaging Library - http://www.pythonware.com/products/pil/
5333
 
 *
5334
 
 * \author Shankar Ganesh <shagan.glare@gmail.com>
5335
 
 */
5336
 
 
5337
 
/** \page Classpstats Class pstats
5338
 
 * \section Syntax
5339
 
 *
5340
 
 * \<Object\> = pstats(\<application name\>, \<time interval\>)
5341
 
 * 
5342
 
 * \<Object\>.start()
5343
 
 * 
5344
 
 * \<Object\>.stop() 
5345
 
 *
5346
 
 * \section Description
5347
 
 *
5348
 
 * This process when run gathers the Memory usage and CPU utilization of all the processes of a particular application at specific time interval.
5349
 
 *
5350
 
 * \section ImplementationDetails
5351
 
 *
5352
 
 * When this functionality is to be used in a python test script you need to create a new object for pstats class.
5353
 
 * 
5354
 
 * The arguments passed while instantiating this class are Application name and Time interval.
5355
 
 * 
5356
 
 * As soon as the \<Object\>.start() method is called in the test script, memory usage and CPU utilization of the application start getting logged into the ldtp log file.
5357
 
 * 
5358
 
 * When \<Object\>.stop is called the thread gathering the information stops. 
5359
 
 *
5360
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5361
 
 *
5362
 
 * \section Example
5363
 
 *
5364
 
 * If I want the resource usage of all processes related to evolution to be logged every 2 seconds, the following statements need to be incorporated in the test script
5365
 
 * 
5366
 
 * xstats = pstats ('evolution', 2)
5367
 
 * 
5368
 
 * xstats.start ()
5369
 
 * 
5370
 
 * \<Test Script\>
5371
 
 * 
5372
 
 * xstats.stop() 
5373
 
 *
5374
 
 * \section Dependency
5375
 
 *
5376
 
 * This functionality depends on the pystatgrab (http://www.i-scream.org/pystatgrab/) package. Make sure you have it installed before using this memory and CPU utilization gathering function in your ldtp test scripts.
5377
 
 *
5378
 
 * \author Subodh Soni <subodhsoni@gmail.com>
5379
 
 */
5380
 
 
5381
 
/** \page wait wait
5382
 
 * \section Syntax
5383
 
 *
5384
 
 * wait ([\<number of seconds to suspend current execution\>])
5385
 
 *
5386
 
 * \section Description
5387
 
 *
5388
 
 * Suspend execution for the specified time period. Default wait time is 5 seconds.
5389
 
 *
5390
 
 * \note Time in seconds.
5391
 
 *
5392
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5393
 
 *
5394
 
 * \section Example
5395
 
 *
5396
 
 * To suspend the current sequence of execution for 5 seconds
5397
 
 * 
5398
 
 * from ldtputils import * 
5399
 
 *
5400
 
 * wait (5) 
5401
 
 *
5402
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5403
 
 * \author Shankar Ganesh <shagan.glare@gmail.com>
5404
 
 *
5405
 
 */
5406
 
 
5407
 
/** \page launchapp launchapp
5408
 
 * \section Syntax
5409
 
 *
5410
 
 * launchapp ('\<application binary name\>'[, argument] [,use additional environment variables for accessibility])
5411
 
 *
5412
 
 * second and third arguments are optional. environment default argument is 1. So the GTK_MODULES and GNOME_ACCESSIBILITY will be set and added to the enivronment variable. Currently the second argument is applicable only when the test is run in local environment.
5413
 
 *
5414
 
 * Second argument is a list, if executed from local session and the same argument is used as sleep time for remote session, but as a single integer value.
5415
 
 *
5416
 
 * NOTE: Incase of remote session, the command line arguments should be part of application name
5417
 
 *
5418
 
 * \section Description
5419
 
 *
5420
 
 * Application name specified as an argument will be launched.
5421
 
 *
5422
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtp.py
5423
 
 *
5424
 
 * \section Example
5425
 
 *
5426
 
 * Launch file-roller application.
5427
 
 *
5428
 
 * from ldtp import * 
5429
 
 *
5430
 
 * launchapp ('file-roller')
5431
 
 *
5432
 
 * launchapp ('gaim', env = 1) # Invoke the application after setting environment variables
5433
 
 *
5434
 
 * launchapp ('file-roller', ['/home/ldtp/test.tar.gz'], env = 0) # Invoke the application with optional command line argument
5435
 
 *
5436
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5437
 
 * \author Shankar Ganesh <shagan.glare@gmail.com>
5438
 
 *
5439
 
 */
5440
 
 
5441
 
/** \page launchapp2 launchapp2
5442
 
 * \section Syntax
5443
 
 *
5444
 
 * launchapp2 ('\<application binary name\>'[, '\<application under test\>' = None[, callAut = False]])
5445
 
 *
5446
 
 * Calls appundertest for the user.
5447
 
 *
5448
 
 * Implicit call to appundertest.
5449
 
 *  Because:
5450
 
 *   * This is usually what a user mean when he calls launchapp.
5451
 
 *   * A newbie user could call appunder very far away from launchapp, and we don't know
5452
 
 *     what could be the consequences of that.
5453
 
 *     * Less typing.
5454
 
 *
5455
 
 * \section Description
5456
 
 *
5457
 
 * Application name specified as an argument will be launched.
5458
 
 *
5459
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5460
 
 *
5461
 
 * \section Example
5462
 
 *
5463
 
 * from ldtp import * 
5464
 
 *
5465
 
 * launchapp2 ('file-roller')
5466
 
 *
5467
 
 * launchapp ('file-roller', callAut = True)
5468
 
 *
5469
 
 * launchapp2 ('gedit', 'gedit', callAut = True)
5470
 
 *
5471
 
 * \author  Sandro Millien <msp@lloedy.com>
5472
 
 *
5473
 
 */
5474
 
 
5475
 
/** \page getactivewin getactivewin
5476
 
 * \section Syntax
5477
 
 *
5478
 
 * getactivewin ()
5479
 
 *
5480
 
 * \section Description
5481
 
 *
5482
 
 * 
5483
 
 *
5484
 
 * \retval The active window title string.
5485
 
 *
5486
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5487
 
 *
5488
 
 * \section Example
5489
 
 *
5490
 
 * title = getactivewin ()
5491
 
 * 
5492
 
 * print 'Current active window title - ' + title
5493
 
 * 
5494
 
 * Gets the current active window title (window that is currently in focus). 
5495
 
 *
5496
 
 * \section Dependency
5497
 
 *
5498
 
 * ltfx binary - http://sourceforge.net/projects/ltfx
5499
 
 *
5500
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5501
 
 * \author Shankar Ganesh <shagan.glare@gmail.com>
5502
 
 *
5503
 
 */
5504
 
 
5505
 
/** \page windowexists windowexists
5506
 
 * \section Syntax
5507
 
 *
5508
 
 * windowexists ('\<window name\>')
5509
 
 *
5510
 
 * \section Description
5511
 
 *
5512
 
 * Check window name exists with the given name.
5513
 
 *
5514
 
 * \retval 1 if window exist and 0 otherwise.
5515
 
 *
5516
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5517
 
 *
5518
 
 * \section Example
5519
 
 *
5520
 
 * windowexists ('Mozilla Firefox')
5521
 
 *
5522
 
 * \section Dependency
5523
 
 *
5524
 
 * ltfx binary - http://sourceforge.net/projects/ltfx
5525
 
 *
5526
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5527
 
 * \author Shankar Ganesh <shagan.glare@gmail.com>
5528
 
 *
5529
 
 */
5530
 
 
5531
 
/** \page partialexists partialexists
5532
 
 * \section Syntax
5533
 
 *
5534
 
 * partialexists ('\<window name\>')
5535
 
 *
5536
 
 * \section Description
5537
 
 *
5538
 
 * Check window name partially matches with the given name.
5539
 
 *
5540
 
 * \retval 1 if window exist and 0 otherwise.
5541
 
 *
5542
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5543
 
 *
5544
 
 * \section Example
5545
 
 *
5546
 
 * partialexists ('Firefox')
5547
 
 *
5548
 
 * \section Dependency
5549
 
 *
5550
 
 * ltfx binary - http://sourceforge.net/projects/ltfx
5551
 
 *
5552
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5553
 
 * \author Shankar Ganesh <shagan.glare@gmail.com>
5554
 
 *
5555
 
 */
5556
 
 
5557
 
/** \page activatewinpartialname activatewinpartialname
5558
 
 * \section Syntax
5559
 
 *
5560
 
 * activatewinpartialname ('\<window name\>')
5561
 
 *
5562
 
 * \section Description
5563
 
 *
5564
 
 * Activate window based on the given name that matches partially.
5565
 
 *
5566
 
 * \retval 1 if window exist and 0 otherwise.
5567
 
 *
5568
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5569
 
 *
5570
 
 * \section Example
5571
 
 *
5572
 
 * activatewinpartialname ('Firefox')
5573
 
 *
5574
 
 * \section Dependency
5575
 
 *
5576
 
 * ltfx binary - http://sourceforge.net/projects/ltfx
5577
 
 *
5578
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5579
 
 * \author Shankar Ganesh <shagan.glare@gmail.com>
5580
 
 *
5581
 
 */
5582
 
 
5583
 
/** \page typekey typekey
5584
 
 * \section Syntax
5585
 
 *
5586
 
 * typekey ('\<string to be typed\>')
5587
 
 *
5588
 
 * \section Description
5589
 
 *
5590
 
 * On the current focus area, the string given as argument will be typed.
5591
 
 *
5592
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5593
 
 *
5594
 
 * \section ImplementationDetails
5595
 
 *
5596
 
 * \retval 1 if window exist and 0 otherwise.
5597
 
 * 
5598
 
 * This function supports
5599
 
 * 
5600
 
 * \<alt\> - for alt key
5601
 
 * 
5602
 
 * \<ctrl\> - for control key
5603
 
 * 
5604
 
 * \<shift\> - for pressing shift key
5605
 
 * 
5606
 
 * \<enter\> - for pressing enter key
5607
 
 * 
5608
 
 * \<tab\> - for pressing tab key
5609
 
 * 
5610
 
 * \<del\> - for pressing del key
5611
 
 * 
5612
 
 * \<bksp\> - for pressing back space key
5613
 
 * 
5614
 
 * \<f1\> - for pressing F1 function key
5615
 
 * 
5616
 
 * ...
5617
 
 * 
5618
 
 * \<f12\> - for pressing F1 function key
5619
 
 * 
5620
 
 * \<up\> - for pressing up arrow key
5621
 
 * 
5622
 
 * \<down\> - for pressing down arrow key
5623
 
 * 
5624
 
 * \<right\> - for pressing right arrow key
5625
 
 * 
5626
 
 * \<left\> - for pressing left arrow key
5627
 
 * 
5628
 
 * \<esc\> - for pressing escape key
5629
 
 * 
5630
 
 * \<space\> - for pressing space bar
5631
 
 * 
5632
 
 * \<home\> - for pressing home key
5633
 
 * 
5634
 
 * \<end\> - for pressing end key
5635
 
 * 
5636
 
 * \<pageup\> - for pressing page up key
5637
 
 * 
5638
 
 * \<pagedown\> - for pressing page down key
5639
 
 * 
5640
 
 * \<prtscrn\> - for pressing print screen key
5641
 
 * 
5642
 
 *
5643
 
 * \section Example
5644
 
 *
5645
 
 * typekey ('\<tab\>testing LDTP using ltfx\<enter\>')
5646
 
 * 
5647
 
 * Intially a tab key will be pressed and then text will be typed and then enter key will be pressed 
5648
 
 *
5649
 
 * \section Dependency
5650
 
 *
5651
 
 * ltfx binary - http://sourceforge.net/projects/ltfx
5652
 
 *
5653
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5654
 
 * \author Shankar Ganesh <shagan.glare@gmail.com>
5655
 
 *
5656
 
 */
5657
 
 
5658
 
/** \page activatewin activatewin
5659
 
 * \section Syntax
5660
 
 *
5661
 
 * activatewin ('\<window name\>')
5662
 
 *
5663
 
 * \section Description
5664
 
 *
5665
 
 * Activate window based on the given name.
5666
 
 *
5667
 
 * \retval 1 if window exist and 0 otherwise.
5668
 
 *
5669
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5670
 
 *
5671
 
 * \section Example
5672
 
 *
5673
 
 * activatewin ('Mozilla Firefox')
5674
 
 *
5675
 
 * \section Dependency
5676
 
 *
5677
 
 * ltfx binary - http://sourceforge.net/projects/ltfx
5678
 
 *
5679
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5680
 
 * \author Shankar Ganesh <shagan.glare@gmail.com>
5681
 
 *
5682
 
 */
5683
 
 
5684
 
/** \page waitwinname waitwinname
5685
 
 * \section Syntax
5686
 
 *
5687
 
 * waitwinname ('\<window name\>')
5688
 
 *
5689
 
 * \section Description
5690
 
 *
5691
 
 * Wait for window with the given name to appear.
5692
 
 *
5693
 
 * \retval 1 if window exist and 0 otherwise.
5694
 
 *
5695
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5696
 
 *
5697
 
 * \section Example
5698
 
 *
5699
 
 * waitwinname ('Mozilla Firefox')
5700
 
 *
5701
 
 * \section Dependency
5702
 
 *
5703
 
 * ltfx binary - http://sourceforge.net/projects/ltfx
5704
 
 *
5705
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5706
 
 * \author Shankar Ganesh <shagan.glare@gmail.com>
5707
 
 *
5708
 
 */
5709
 
 
5710
 
/** \page waitwinpartialname waitwinpartialname
5711
 
 * \section Syntax
5712
 
 *
5713
 
 * waitwinpartialname ('\<window name\>')
5714
 
 *
5715
 
 * \section Description
5716
 
 *
5717
 
 * Wait for window with the given name partially matches to appear.
5718
 
 *
5719
 
 * \retval 1 if window exist and 0 otherwise.
5720
 
 *
5721
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5722
 
 *
5723
 
 * \section Example
5724
 
 *
5725
 
 * waitwinpartialname ('Firefox')
5726
 
 *
5727
 
 * \section Dependency
5728
 
 *
5729
 
 * ltfx binary - http://sourceforge.net/projects/ltfx
5730
 
 *
5731
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5732
 
 * \author Shankar Ganesh <shagan.glare@gmail.com>
5733
 
 *
5734
 
 */
5735
 
 
5736
 
/** \page windowuptime windowuptime
5737
 
 * \section Syntax
5738
 
 *
5739
 
 * windowuptime(['\<window name\>'])
5740
 
 *
5741
 
 * \section Description
5742
 
 *
5743
 
 * Give the window up time
5744
 
 *
5745
 
 * \retval startime, endtime (python datetime object)
5746
 
 *
5747
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5748
 
 *
5749
 
 * \section Example
5750
 
 *
5751
 
 * windowuptime('dlgChatWindow')
5752
 
 *
5753
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5754
 
 *
5755
 
 */
5756
 
 
5757
 
/** \page activatewindow activatewindow
5758
 
 * \section Syntax
5759
 
 *
5760
 
 * activatewindow(['\<window name\>'])
5761
 
 *
5762
 
 * \section Description
5763
 
 *
5764
 
 * Activate window based on the given name, default None. If None,
5765
 
 * will activate all window one by one
5766
 
 *
5767
 
 * \retval None
5768
 
 *
5769
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5770
 
 *
5771
 
 * \section Example
5772
 
 *
5773
 
 * activatewindow('Mozilla Firefox')
5774
 
 *
5775
 
 * \section Dependency
5776
 
 *
5777
 
 * wnck, pygtk python library
5778
 
 *
5779
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5780
 
 * \author Arvind Patil <apatil@vmware.com>
5781
 
 *
5782
 
 */
5783
 
 
5784
 
/** \page maximizewindow maximizewindow
5785
 
 * \section Syntax
5786
 
 *
5787
 
 * maximizewindow(['\<window name\>'])
5788
 
 *
5789
 
 * \section Description
5790
 
 *
5791
 
 * Maximize window based on the given name, default None. If None,
5792
 
 * will maximize all window one by one
5793
 
 *
5794
 
 * \retval None
5795
 
 *
5796
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5797
 
 *
5798
 
 * \section Example
5799
 
 *
5800
 
 * maximizewindow('Mozilla Firefox')
5801
 
 *
5802
 
 * \section Dependency
5803
 
 *
5804
 
 * wnck, pygtk python library
5805
 
 *
5806
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5807
 
 * \author Arvind Patil <apatil@vmware.com>
5808
 
 *
5809
 
 */
5810
 
 
5811
 
/** \page minimizewindow minimizewindow
5812
 
 * \section Syntax
5813
 
 *
5814
 
 * minimizewindow(['\<window name\>'])
5815
 
 *
5816
 
 * \section Description
5817
 
 *
5818
 
 * Minimize window based on the given name, default None. If None,
5819
 
 * will minimize all window one by one
5820
 
 *
5821
 
 * \retval None
5822
 
 *
5823
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5824
 
 *
5825
 
 * \section Example
5826
 
 *
5827
 
 * minimizewindow('Mozilla Firefox')
5828
 
 *
5829
 
 * \section Dependency
5830
 
 *
5831
 
 * wnck, pygtk python library
5832
 
 *
5833
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5834
 
 * \author Arvind Patil <apatil@vmware.com>
5835
 
 *
5836
 
 */
5837
 
 
5838
 
/** \page closewindow closewindow
5839
 
 * \section Syntax
5840
 
 *
5841
 
 * closewindow(['\<window name\>'])
5842
 
 *
5843
 
 * \section Description
5844
 
 *
5845
 
 * Close window based on the given name, default None. If None,
5846
 
 * will close all window one by one
5847
 
 *
5848
 
 * \retval None
5849
 
 *
5850
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtputils.py
5851
 
 *
5852
 
 * \section Example
5853
 
 *
5854
 
 * closewindow('Mozilla Firefox')
5855
 
 *
5856
 
 * \section Dependency
5857
 
 *
5858
 
 * wnck, pygtk python library
5859
 
 *
5860
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5861
 
 * \author Arvind Patil <apatil@vmware.com>
5862
 
 *
5863
 
 */
5864
 
 
5865
 
/** \page getpanelchildcount getpanelchildcount
5866
 
 * \section Syntax
5867
 
 *
5868
 
 * getpanelchildcount ('\<window name\>', '\<component name\>')
5869
 
 *
5870
 
 * \section Description
5871
 
 *
5872
 
 * Gets the number of childs available under the given panel
5873
 
 *
5874
 
 * \retval Returns the child count if present, else -1, if unable to find child count
5875
 
 *
5876
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/panel.c
5877
 
 *
5878
 
 * \section Example
5879
 
 *
5880
 
 * With respect to gedit application
5881
 
 *
5882
 
 * from ldtp import *
5883
 
 *
5884
 
 * getpanelchildcount ('*-gedit', 'pnl0')
5885
 
 *
5886
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5887
 
 *
5888
 
 */
5889
 
 
5890
 
/** \page bindtext bindtext
5891
 
 * \section Syntax
5892
 
 *
5893
 
 * bindtext ('\<package name\>', '\<locale directory\>'[, '\<mode\>'])
5894
 
 *
5895
 
 * \section Description
5896
 
 *
5897
 
 * 
5898
 
 *
5899
 
 * \retval Returns 1 on success, LdtpExecutionError exception will be thrown on failure
5900
 
 *
5901
 
 * Refer:
5902
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
5903
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/localization.c
5904
 
 *
5905
 
 * \section Example
5906
 
 *
5907
 
 * For mo file with name: "/opt/gnome/share/locale/ta/LC_MESSAGES/gedit.mo"
5908
 
 *
5909
 
 * bindtext ('gedit', '/opt/gnome/share/locale')
5910
 
 *
5911
 
 * \author Premkumar J <prem.jothimani@gmail.com>
5912
 
 *
5913
 
 */
5914
 
 
5915
 
/** \page setlocale setlocale
5916
 
 * \section Syntax
5917
 
 *
5918
 
 * setlocale (['\<LANG\>'])
5919
 
 *
5920
 
 * \section Description
5921
 
 *
5922
 
 * 
5923
 
 *
5924
 
 * \retval Returns 1 on success, LdtpExecutionError exception will be thrown on failure
5925
 
 *
5926
 
 * Refer:
5927
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
5928
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/localization.c
5929
 
 *
5930
 
 * \section Example
5931
 
 *
5932
 
 * \todo
5933
 
 *
5934
 
 * \author Premkumar J <prem.jothimani@gmail.com>
5935
 
 *
5936
 
 */
5937
 
 
5938
 
/** \page setloglevel setloglevel
5939
 
 * \section Syntax
5940
 
 *
5941
 
 * setloglevel (\<log level\>)
5942
 
 *
5943
 
 * \section Options
5944
 
 *
5945
 
 * List of log levels are available here - http://docs.python.org/lib/module-logging.html
5946
 
 *
5947
 
 * \section Description
5948
 
 *
5949
 
 * Set the log level, which will be used in client side logging. Default log level set is logging.WARNING
5950
 
 *
5951
 
 * \section ImplementationDetails
5952
 
 *
5953
 
 * Implemented based on python logging formats
5954
 
 *
5955
 
 * \retval Returns 1 on success, 0 on failure
5956
 
 *
5957
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtp.py
5958
 
 *
5959
 
 * \section Example
5960
 
 *
5961
 
 * setloglevel (logging.WARNING)
5962
 
 *
5963
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5964
 
 *
5965
 
 */
5966
 
 
5967
 
/** \page addlogger addlogger
5968
 
 * \section Syntax
5969
 
 *
5970
 
 * addlogger ('\<log configuration file\>')
5971
 
 *
5972
 
 * \section Description
5973
 
 *
5974
 
 * Add more python logging formats with a configuration file format based on python logging format
5975
 
 *
5976
 
 * \section ImplementationDetails
5977
 
 *
5978
 
 * Implemented based on python logging formats
5979
 
 *
5980
 
 * \retval Returns 1 on success
5981
 
 *
5982
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtp.py
5983
 
 *
5984
 
 * \section Example
5985
 
 *
5986
 
 * addlogger ('/etc/ldtp.conf')
5987
 
 *
5988
 
 * \section Configration
5989
 
 *
5990
 
 * Refer: Python logging format configuration file
5991
 
 *
5992
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
5993
 
 *
5994
 
 */
5995
 
 
5996
 
/** \page mouseleftclick mouseleftclick
5997
 
 * \section Syntax
5998
 
 *
5999
 
 * mouseleftclick ('\<window name\>', '\<object name\>')
6000
 
 *
6001
 
 * \section Description
6002
 
 *
6003
 
 * 
6004
 
 *
6005
 
 * \retval Returns 1 on success, LdtpExecutionError exception will be thrown on failure
6006
 
 *
6007
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/device.c
6008
 
 *
6009
 
 * \section Example
6010
 
 *
6011
 
 * \todo
6012
 
 *
6013
 
 * \author Prashanth Mohan <prashmohan@gmail.com>
6014
 
 *
6015
 
 */
6016
 
 
6017
 
/** \page mouserightclick mouserightclick
6018
 
 * \section Syntax
6019
 
 *
6020
 
 * mouserightclick ('\<window name\>', '\<object name\>')
6021
 
 *
6022
 
 * \section Description
6023
 
 *
6024
 
 * 
6025
 
 *
6026
 
 * \retval Returns 1 on success, LdtpExecutionError exception will be thrown on failure
6027
 
 *
6028
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/device.c
6029
 
 *
6030
 
 * \section Example
6031
 
 *
6032
 
 * \todo
6033
 
 *
6034
 
 * \author Prashanth Mohan <prashmohan@gmail.com>
6035
 
 *
6036
 
 */
6037
 
 
6038
 
/** \page mousemove mousemove
6039
 
 * \section Syntax
6040
 
 *
6041
 
 * mousemove ('\<window name\>', '\<object name\>')
6042
 
 *
6043
 
 * \section Description
6044
 
 *
6045
 
 * 
6046
 
 *
6047
 
 * \retval Returns 1 on success, LdtpExecutionError exception will be thrown on failure
6048
 
 *
6049
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/device.c
6050
 
 *
6051
 
 * \section Example
6052
 
 *
6053
 
 * \todo
6054
 
 *
6055
 
 * \author Prashanth Mohan <prashmohan@gmail.com>
6056
 
 *
6057
 
 */
6058
 
 
6059
 
/** \page enterstring enterstring
6060
 
 * \section Syntax
6061
 
 *
6062
 
 * enterstring ('\<window name\>', '\<object name\>', '\<data\>')
6063
 
 *
6064
 
 * \section Description
6065
 
 *
6066
 
 * Functionality of enterstring is similar to typekey of LTFX project. Main difference is this function works based on accessibility. So, we could specify the window name, object name and finally the data string.
6067
 
 *
6068
 
 * \retval Returns 1 on success, LdtpExecutionError exception will be thrown on failure
6069
 
 *
6070
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/device.c
6071
 
 *
6072
 
 * \section Example
6073
 
 *
6074
 
 * enterstring ('*-gedit', 'txt0', 'Testing LDTP\'s enterstring function')
6075
 
 *
6076
 
 * This function supports
6077
 
 * 
6078
 
 * \<alt\> - for alt key
6079
 
 * 
6080
 
 * \<ctrl\> - for control key
6081
 
 * 
6082
 
 * \<shift\> - for pressing shift key
6083
 
 * 
6084
 
 * \<enter\> - for pressing enter key
6085
 
 * 
6086
 
 * \<tab\> - for pressing tab key
6087
 
 * 
6088
 
 * \<del\> - for pressing del key
6089
 
 * 
6090
 
 * \<bksp\> - for pressing back space key
6091
 
 * 
6092
 
 * \<f1\> - for pressing F1 function key
6093
 
 * 
6094
 
 * ...
6095
 
 * 
6096
 
 * \<f12\> - for pressing F1 function key
6097
 
 * 
6098
 
 * \<up\> - for pressing up arrow key
6099
 
 * 
6100
 
 * \<down\> - for pressing down arrow key
6101
 
 * 
6102
 
 * \<right\> - for pressing right arrow key
6103
 
 * 
6104
 
 * \<left\> - for pressing left arrow key
6105
 
 * 
6106
 
 * \<esc\> - for pressing escape key
6107
 
 * 
6108
 
 * \<space\> - for pressing space bar
6109
 
 * 
6110
 
 * \<home\> - for pressing home key
6111
 
 * 
6112
 
 * \<end\> - for pressing end key
6113
 
 * 
6114
 
 * \<pageup\> - for pressing page up key
6115
 
 * 
6116
 
 * \<pagedown\> - for pressing page down key
6117
 
 * 
6118
 
 * \<prtscrn\> - for pressing print screen key
6119
 
 * 
6120
 
 *
6121
 
 * \author Prashanth Mohan <prashmohan@gmail.com>
6122
 
 *
6123
 
 */
6124
 
 
6125
 
/** \page generatekeyevent generatekeyevent
6126
 
 * \section Syntax
6127
 
 *
6128
 
 * generatekeyevent ('\<data\>')
6129
 
 *
6130
 
 * \section Description
6131
 
 *
6132
 
 * Functionality of generatekeyevent is similar to typekey of LTFX project.
6133
 
 *
6134
 
 * \section ImplementationDetails
6135
 
 *
6136
 
 * Used SPI_generateKeyboardEvent to generate the keyboard events.
6137
 
 *
6138
 
 * \retval Returns 1 on success, LdtpExecutionError exception will be thrown on failure
6139
 
 *
6140
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/device.c
6141
 
 *
6142
 
 * \section Example
6143
 
 *
6144
 
 * generatekeyevent ('Testing LDTP\'s enterstring function')
6145
 
 *
6146
 
 * This function supports
6147
 
 * 
6148
 
 * \<alt\> - for alt key
6149
 
 * 
6150
 
 * \<ctrl\> - for control key
6151
 
 * 
6152
 
 * \<shift\> - for pressing shift key
6153
 
 * 
6154
 
 * \<enter\> - for pressing enter key
6155
 
 * 
6156
 
 * \<tab\> - for pressing tab key
6157
 
 * 
6158
 
 * \<del\> - for pressing del key
6159
 
 * 
6160
 
 * \<bksp\> - for pressing back space key
6161
 
 * 
6162
 
 * \<f1\> - for pressing F1 function key
6163
 
 * 
6164
 
 * ...
6165
 
 * 
6166
 
 * \<f12\> - for pressing F1 function key
6167
 
 * 
6168
 
 * \<up\> - for pressing up arrow key
6169
 
 * 
6170
 
 * \<down\> - for pressing down arrow key
6171
 
 * 
6172
 
 * \<right\> - for pressing right arrow key
6173
 
 * 
6174
 
 * \<left\> - for pressing left arrow key
6175
 
 * 
6176
 
 * \<esc\> - for pressing escape key
6177
 
 * 
6178
 
 * \<space\> - for pressing space bar
6179
 
 * 
6180
 
 * \<home\> - for pressing home key
6181
 
 * 
6182
 
 * \<end\> - for pressing end key
6183
 
 * 
6184
 
 * \<pageup\> - for pressing page up key
6185
 
 * 
6186
 
 * \<pagedown\> - for pressing page down key
6187
 
 * 
6188
 
 * \<prtscrn\> - for pressing print screen key
6189
 
 * 
6190
 
 * NOTE: \<\<\> - To enter \< symbol, it has to be escaped within \<\>
6191
 
 * 
6192
 
 *
6193
 
 * \author Prashanth Mohan <prashmohan@gmail.com>
6194
 
 *
6195
 
 */
6196
 
 
6197
 
/** \page keyrelease keyrelease
6198
 
 * \section Syntax
6199
 
 *
6200
 
 * keyrelease ('\<data\>')
6201
 
 *
6202
 
 * \section Description
6203
 
 *
6204
 
 * Functionality of keyrelease is similar to typekey of LTFX project.
6205
 
 *
6206
 
 * \section ImplementationDetails
6207
 
 *
6208
 
 * Used SPI_generateKeyboardEvent to generate the keyboard events.
6209
 
 *
6210
 
 * \retval Returns 1 on success, LdtpExecutionError exception will be thrown on failure
6211
 
 *
6212
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/device.c
6213
 
 *
6214
 
 * \section Example
6215
 
 *
6216
 
 * keypress ('\<shift\>');generatekeyevent ('hELLO');keyrelease ('\<shift\>');generatekeyevent ('\<space\>World')
6217
 
 *
6218
 
 * This function supports
6219
 
 * 
6220
 
 * \<alt\> - for alt key
6221
 
 * 
6222
 
 * \<ctrl\> - for control key
6223
 
 * 
6224
 
 * \<shift\> - for pressing shift key
6225
 
 * 
6226
 
 * \<enter\> - for pressing enter key
6227
 
 * 
6228
 
 * \<tab\> - for pressing tab key
6229
 
 * 
6230
 
 * \<del\> - for pressing del key
6231
 
 * 
6232
 
 * \<bksp\> - for pressing back space key
6233
 
 * 
6234
 
 * \<f1\> - for pressing F1 function key
6235
 
 * 
6236
 
 * ...
6237
 
 * 
6238
 
 * \<f12\> - for pressing F1 function key
6239
 
 * 
6240
 
 * \<up\> - for pressing up arrow key
6241
 
 * 
6242
 
 * \<down\> - for pressing down arrow key
6243
 
 * 
6244
 
 * \<right\> - for pressing right arrow key
6245
 
 * 
6246
 
 * \<left\> - for pressing left arrow key
6247
 
 * 
6248
 
 * \<esc\> - for pressing escape key
6249
 
 * 
6250
 
 * \<space\> - for pressing space bar
6251
 
 * 
6252
 
 * \<home\> - for pressing home key
6253
 
 * 
6254
 
 * \<end\> - for pressing end key
6255
 
 * 
6256
 
 * \<pageup\> - for pressing page up key
6257
 
 * 
6258
 
 * \<pagedown\> - for pressing page down key
6259
 
 * 
6260
 
 * \<prtscrn\> - for pressing print screen key
6261
 
 * 
6262
 
 *
6263
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
6264
 
 *
6265
 
 */
6266
 
 
6267
 
/** \page keypress keypress
6268
 
 * \section Syntax
6269
 
 *
6270
 
 * keypress ('\<data\>')
6271
 
 *
6272
 
 * \section Description
6273
 
 *
6274
 
 * Functionality of keypress is similar to typekey of LTFX project.
6275
 
 *
6276
 
 * \section ImplementationDetails
6277
 
 *
6278
 
 * Used SPI_generateKeyboardEvent to generate the keyboard events.
6279
 
 *
6280
 
 * \retval Returns 1 on success, LdtpExecutionError exception will be thrown on failure
6281
 
 *
6282
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/device.c
6283
 
 *
6284
 
 * \section Example
6285
 
 *
6286
 
 * keypress ('\<shift\>');generatekeyevent ('hELLO');keyrelease ('\<shift\>');generatekeyevent ('\<space\>World')
6287
 
 *
6288
 
 * This function supports
6289
 
 * 
6290
 
 * \<alt\> - for alt key
6291
 
 * 
6292
 
 * \<ctrl\> - for control key
6293
 
 * 
6294
 
 * \<shift\> - for pressing shift key
6295
 
 * 
6296
 
 * \<enter\> - for pressing enter key
6297
 
 * 
6298
 
 * \<tab\> - for pressing tab key
6299
 
 * 
6300
 
 * \<del\> - for pressing del key
6301
 
 * 
6302
 
 * \<bksp\> - for pressing back space key
6303
 
 * 
6304
 
 * \<f1\> - for pressing F1 function key
6305
 
 * 
6306
 
 * ...
6307
 
 * 
6308
 
 * \<f12\> - for pressing F1 function key
6309
 
 * 
6310
 
 * \<up\> - for pressing up arrow key
6311
 
 * 
6312
 
 * \<down\> - for pressing down arrow key
6313
 
 * 
6314
 
 * \<right\> - for pressing right arrow key
6315
 
 * 
6316
 
 * \<left\> - for pressing left arrow key
6317
 
 * 
6318
 
 * \<esc\> - for pressing escape key
6319
 
 * 
6320
 
 * \<space\> - for pressing space bar
6321
 
 * 
6322
 
 * \<home\> - for pressing home key
6323
 
 * 
6324
 
 * \<end\> - for pressing end key
6325
 
 * 
6326
 
 * \<pageup\> - for pressing page up key
6327
 
 * 
6328
 
 * \<pagedown\> - for pressing page down key
6329
 
 * 
6330
 
 * \<prtscrn\> - for pressing print screen key
6331
 
 * 
6332
 
 *
6333
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
6334
 
 *
6335
 
 */
6336
 
 
6337
 
/** \page generatemouseevent generatemouseevent
6338
 
 * \section Syntax
6339
 
 *
6340
 
 * generatemouseevent (x, y [,'\<options\>'])
6341
 
 *
6342
 
 * \section Description
6343
 
 *
6344
 
 * Functionality of generatemouseevent, generates the default (left
6345
 
 * click) or specified mouse event in the given X and Y
6346
 
 * coordinates.
6347
 
 *
6348
 
 * \subsection Note
6349
 
 *
6350
 
 * This functionality depends on screen resolution / coordinates. Also
6351
 
 * the event will be generated on the currently focused window.
6352
 
 *
6353
 
 * \subsection Options
6354
 
 *
6355
 
 * b1c - Left button click
6356
 
 *
6357
 
 * b2c - Middle button click
6358
 
 *
6359
 
 * b3c - Right button click
6360
 
 *
6361
 
 * b1d - Left button double click
6362
 
 *
6363
 
 * b2d - Middle button double click
6364
 
 *
6365
 
 * b3d - Right button double click
6366
 
 *
6367
 
 * abs - absolute motion
6368
 
 *
6369
 
 * rel - relative motion
6370
 
 *
6371
 
 * \section ImplementationDetails
6372
 
 *
6373
 
 * Used SPI_generateMouseEvent to generate the mouse events.
6374
 
 *
6375
 
 * \retval Returns 1 on success, LdtpExecutionError exception will be thrown on failure
6376
 
 *
6377
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
6378
 
 *
6379
 
 * \section Example
6380
 
 *
6381
 
 * generatemouseevent (100, 200)
6382
 
 *
6383
 
 *
6384
 
 * generatemouseevent (100, 200, "b1d") # Generate double click event
6385
 
 *
6386
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
6387
 
 *
6388
 
 */
6389
 
 
6390
 
/** \page stopscriptengine stopscriptengine
6391
 
 * \section Syntax
6392
 
 *
6393
 
 * stopscriptengine ()
6394
 
 *
6395
 
 * \section Description
6396
 
 *
6397
 
 * Stops the LDTP engine, free all the resources. If we want to stop LDTP service, we can use this function to silently die.
6398
 
 *
6399
 
 * \retval None
6400
 
 *
6401
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
6402
 
 *
6403
 
 * \section Example
6404
 
 *
6405
 
 * from ldtp import *
6406
 
 *
6407
 
 * stopscriptengine ()
6408
 
 *
6409
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
6410
 
 *
6411
 
 */
6412
 
 
6413
 
/** \page hasstate hasstate
6414
 
 * \section Syntax
6415
 
 *
6416
 
 * hasstate ('<window name\>', '<object name\>', <object SPI state-1>[, ..., <object SPI state-n>])
6417
 
 *
6418
 
 * \section Description
6419
 
 *
6420
 
 * Checks the SPI state of the given object.
6421
 
 *
6422
 
 * \retval 1 on success, 0 on failure
6423
 
 *
6424
 
 * Refer:
6425
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/client-handler.c
6426
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtp.py
6427
 
 *
6428
 
 * \section Example
6429
 
 *
6430
 
 * With respect to gedit window, first tab
6431
 
 *
6432
 
 * from ldtp import *
6433
 
 *
6434
 
 * hasstate ('*-gedit', 'txt0', state.FOCUSABLE)
6435
 
 *
6436
 
 * hasstate ('*-gedit', 'txt0', state.FOCUSABLE, state.VISIBLE)
6437
 
 *
6438
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
6439
 
 *
6440
 
 */
6441
 
 
6442
 
/** \page press press
6443
 
 * \section Syntax
6444
 
 *
6445
 
 * press ('<window name\>', '<object name\>')
6446
 
 *
6447
 
 * \section Description
6448
 
 *
6449
 
 * Toggle's the button state.
6450
 
 *
6451
 
 * \retval 1 on success, 0 on failure
6452
 
 *
6453
 
 * Refer:
6454
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/src/toggle-button.c
6455
 
 * http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtp.py
6456
 
 *
6457
 
 * \section Example
6458
 
 *
6459
 
 * \todo
6460
 
 *
6461
 
 * \author Rodney Dawes <dobey@novell.com>
6462
 
 *
6463
 
 */
6464
 
 
6465
 
/** \page objectexist objectexist
6466
 
 * \section Syntax
6467
 
 *
6468
 
 * objectexist ('<window name\>', '<object name\>')
6469
 
 *
6470
 
 * \section Description
6471
 
 *
6472
 
 * To check whether a component exist in a given window
6473
 
 *
6474
 
 * \retval 1 on success, 0 on failure
6475
 
 *
6476
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtp.py
6477
 
 *
6478
 
 * \section Example
6479
 
 *
6480
 
 * \todo
6481
 
 *
6482
 
 * \author Rodney Dawes <dobey@novell.com>
6483
 
 *
6484
 
 */
6485
 
 
6486
 
/** \page appundertest appundertest
6487
 
 * \section Syntax
6488
 
 *
6489
 
 * appundertest ('\<accessibility application name\>')
6490
 
 *
6491
 
 * \section Description
6492
 
 *
6493
 
 * First try to find the window under the given application name, if not found then try to find it from the global list.
6494
 
 *
6495
 
 * \retval 1 on success, 0 on failure
6496
 
 *
6497
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtp.py
6498
 
 *
6499
 
 * \section Example
6500
 
 *
6501
 
 * appundertest ('gedit')
6502
 
 *
6503
 
 * If two window's having gedit title and only one window belongs to gedit application, even though, its first in the accessibility list, based on the above call, any operation on '*gedit' window operation, the event will be fired on gedit application only.
6504
 
 * http://lists.freedesktop.org/archives/ldtp-dev/2009-February/000764.html
6505
 
 *
6506
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
6507
 
 *
6508
 
 */
6509
 
 
6510
 
/** \page objtimeout objtimeout
6511
 
 * \section Syntax
6512
 
 *
6513
 
 * objtimeout ([guiTimeOut])
6514
 
 *
6515
 
 * \section Description
6516
 
 *
6517
 
 * Instead of setting an environment variable you can change the object time out from default 5 seconds to what ever time period. guiTimeOut should be > 0.
6518
 
 *
6519
 
 * \retval 1 on success, 0 on failure
6520
 
 *
6521
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtp.py
6522
 
 *
6523
 
 * \section Example
6524
 
 *
6525
 
 * objtimeout (10)
6526
 
 *
6527
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
6528
 
 *
6529
 
 */
6530
 
 
6531
 
/** \page guitimeout guitimeout
6532
 
 * \section Syntax
6533
 
 *
6534
 
 * guitimeout ([guiTimeOut])
6535
 
 *
6536
 
 * \section Description
6537
 
 *
6538
 
 * Instead of setting an environment variable you can change the object time out from default 30 seconds to what ever time period. guiTimeOut should be > 0.
6539
 
 *
6540
 
 * \retval 1 on success, 0 on failure
6541
 
 *
6542
 
 * Refer: http://cgit.freedesktop.org/ldtp/ldtp/tree/python/ldtp.py
6543
 
 *
6544
 
 * \section Example
6545
 
 *
6546
 
 * guitimeout (10)
6547
 
 *
6548
 
 * \author Nagappan Alagappan <nagappan@gmail.com>
6549
 
 *
6550
 
 */