Changeset View
Changeset View
Standalone View
Standalone View
doc/useractions.docbook
Show All 34 Lines | 19 | <sect1 id="useractions"> | |||
---|---|---|---|---|---|
35 | ~/.local/share/krusader/useractions.xml</filename> or <filename>krusader/useraction.xml</filename> in the directory which can be determined using the <userinput>qtpaths --paths GenericDataLocation</userinput> command. | 35 | ~/.local/share/krusader/useractions.xml</filename> or <filename>krusader/useraction.xml</filename> in the directory which can be determined using the <userinput>qtpaths --paths GenericDataLocation</userinput> command. | ||
36 | Several | 36 | Several | ||
37 | <link linkend="useraction-xml">examples</link> are included in the | 37 | <link linkend="useraction-xml">examples</link> are included in the | ||
38 | documentation. UserActions can be edited / added / imported / | 38 | documentation. UserActions can be edited / added / imported / | ||
39 | exported by using ActionMan. The default UserActions are stored | 39 | exported by using ActionMan. The default UserActions are stored | ||
40 | in | 40 | in | ||
41 | <filename> | 41 | <filename> | ||
42 | /usr/share/krusader/useraction-examples.xml</filename>. | 42 | /usr/share/krusader/useraction-examples.xml</filename>. | ||
43 | UserActions can appear nearly everywhere where "normal" KActions | 43 | UserActions can appear nearly everywhere where <quote>normal</quote> KActions | ||
44 | can be placed. The actions can even be placed in the menu bar, but for that the | 44 | can be placed. The actions can even be placed in the menu bar, but for that the | ||
45 | <filename>krusaderui.rc</filename> file must be edited. A few | 45 | <filename>krusaderui.rc</filename> file must be edited. A few | ||
46 | examples:</para> | 46 | examples:</para> | ||
47 | <itemizedlist> | 47 | <itemizedlist> | ||
48 | <listitem> | 48 | <listitem> | ||
49 | <para> | 49 | <para> | ||
50 | <link linkend="useractions-menu">Useractions Menu</link> | 50 | <link linkend="useractions-menu">Useractions Menu</link> | ||
51 | </para> | 51 | </para> | ||
▲ Show 20 Lines • Show All 145 Lines • ▼ Show 20 Line(s) | 193 | <listitem> | |||
197 | <guimenuitem>What's This</guimenuitem> if you | 197 | <guimenuitem>What's This</guimenuitem> if you | ||
198 | <keycombo action="simul">&Shift; | 198 | <keycombo action="simul">&Shift; | ||
199 | <keycap>F1</keycap></keycombo> click on your | 199 | <keycap>F1</keycap></keycombo> click on your | ||
200 | UserAction.</para> | 200 | UserAction.</para> | ||
201 | </listitem> | 201 | </listitem> | ||
202 | <listitem> | 202 | <listitem> | ||
203 | <para> | 203 | <para> | ||
204 | <guimenuitem>Command</guimenuitem>: The command which | 204 | <guimenuitem>Command</guimenuitem>: The command which | ||
205 | will be executed. You can add placeholder using a GUI with | 205 | will be executed. You can add placeholder using a &GUI; with | ||
206 | the | 206 | the <guibutton>add</guibutton> button.</para> | ||
207 | <guibutton>add</guibutton> button.</para> | | |||
208 | </listitem> | 207 | </listitem> | ||
209 | <listitem> | 208 | <listitem> | ||
210 | <para> | 209 | <para> | ||
211 | <guimenuitem>Workdir</guimenuitem>: The working directory | 210 | <guimenuitem>Workdir</guimenuitem>: The working directory | ||
212 | for the command which will be executed.</para> | 211 | for the command which will be executed.</para> | ||
213 | </listitem> | 212 | </listitem> | ||
214 | <listitem> | 213 | <listitem> | ||
215 | <para> | 214 | <para> | ||
Show All 18 Lines | 232 | <listitem> | |||
234 | <para> | 233 | <para> | ||
235 | <guimenuitem>Collect output</guimenuitem>: Collects the | 234 | <guimenuitem>Collect output</guimenuitem>: Collects the | ||
236 | output of the executed program in a &GUI; | 235 | output of the executed program in a &GUI; | ||
237 | window.</para> | 236 | window.</para> | ||
238 | </listitem> | 237 | </listitem> | ||
239 | <listitem> | 238 | <listitem> | ||
240 | <para> | 239 | <para> | ||
241 | <guimenuitem>Separate standard error</guimenuitem>: | 240 | <guimenuitem>Separate standard error</guimenuitem>: | ||
242 | When "Collect output" is used the stdout and stderr are | 241 | When <quote>Collect output</quote> is used the stdout and stderr are | ||
243 | separately collected.</para> | 242 | separately collected.</para> | ||
244 | </listitem> | 243 | </listitem> | ||
245 | </itemizedlist> | 244 | </itemizedlist> | ||
246 | </listitem> | 245 | </listitem> | ||
247 | <listitem> | 246 | <listitem> | ||
248 | <para> | 247 | <para> | ||
249 | <guimenuitem>Command accepts</guimenuitem>:</para> | 248 | <guimenuitem>Command accepts</guimenuitem>:</para> | ||
250 | <itemizedlist> | 249 | <itemizedlist> | ||
251 | <listitem> | 250 | <listitem> | ||
252 | <para> | 251 | <para> | ||
253 | <guimenuitem>Local files (no URLs)</guimenuitem>: Tells | 252 | <guimenuitem>Local files only (no &URL;s)</guimenuitem>: Tells | ||
254 | the placeholder it should return local addresses.</para> | 253 | the placeholder it should return local addresses.</para> | ||
255 | </listitem> | 254 | </listitem> | ||
256 | <listitem> | 255 | <listitem> | ||
257 | <para> | 256 | <para> | ||
258 | <guimenuitem>URLs (remote and local)</guimenuitem>: | 257 | <guimenuitem>&URL;s (remote and local)</guimenuitem>: | ||
259 | Tells the placeholder it should return | 258 | Tells the placeholder it should return | ||
260 | &URL;s.</para> | 259 | &URL;s.</para> | ||
261 | </listitem> | 260 | </listitem> | ||
262 | </itemizedlist> | 261 | </itemizedlist> | ||
263 | </listitem> | 262 | </listitem> | ||
264 | <!-- Not yet implemented, but will be after 1.50 stable is released | 263 | <!-- Not yet implemented, but will be after 1.50 stable is released | ||
265 | <listitem><para><guimenuitem>On multiple selection</guimenuitem>: </para> | 264 | <listitem><para><guimenuitem>On multiple selection</guimenuitem>: </para> | ||
266 | <itemizedlist> | 265 | <itemizedlist> | ||
Show All 11 Lines | 275 | <listitem> | |||
278 | <guimenuitem>Enabled</guimenuitem>: if checked, the useraction is shown in the <link linkend="useractions">User Menu</link>, | 277 | <guimenuitem>Enabled</guimenuitem>: if checked, the useraction is shown in the <link linkend="useractions">User Menu</link>, | ||
279 | otherwise the useraction will be hidden.</para> | 278 | otherwise the useraction will be hidden.</para> | ||
280 | </listitem> | 279 | </listitem> | ||
281 | </itemizedlist> | 280 | </itemizedlist> | ||
282 | <para> | 281 | <para> | ||
283 | <emphasis role="bold">Command-line syntax</emphasis> | 282 | <emphasis role="bold">Command-line syntax</emphasis> | ||
284 | </para> | 283 | </para> | ||
285 | <para>Basically, everything you type in the command line will get | 284 | <para>Basically, everything you type in the command line will get | ||
286 | executed (if you type "ls -l", "ls -l" gets executed). You have | 285 | executed (if you type <quote>ls -l</quote>, <quote>ls -l</quote> gets executed). You have | ||
287 | the possibility to get a character string from | 286 | the possibility to get a character string from | ||
288 | &krusader; which represents the current state of the | 287 | &krusader; which represents the current state of the | ||
289 | panel. This is done using placeholders. A placeholder begins with | 288 | panel. This is done using placeholders. A placeholder begins with | ||
290 | a percent-sign ('%') and is followed by a panel indicator ('a' | 289 | a percent-sign ('%') and is followed by a panel indicator ('a' | ||
291 | for the active, 'o' for the other, 'l' for the left and 'r' for | 290 | for the active, 'o' for the other, 'l' for the left and 'r' for | ||
292 | the right panel. If the placeholder does not need a panel to | 291 | the right panel. If the placeholder does not need a panel to | ||
293 | operate on, you have to indicate this by an underscore ('_')). | 292 | operate on, you have to indicate this by an underscore ('_')). | ||
294 | Then comes the name of the placeholder (see the list below), | 293 | Then comes the name of the placeholder (see the list below), | ||
Show All 21 Lines | 303 | <itemizedlist> | |||
316 | </listitem> | 315 | </listitem> | ||
317 | <listitem> | 316 | <listitem> | ||
318 | <para> | 317 | <para> | ||
319 | <userinput>Count</userinput> - replaced by the number of | 318 | <userinput>Count</userinput> - replaced by the number of | ||
320 | <first parameter></para> | 319 | <first parameter></para> | ||
321 | <orderedlist> | 320 | <orderedlist> | ||
322 | <listitem> | 321 | <listitem> | ||
323 | <para>Parameter: Which items; | 322 | <para>Parameter: Which items; | ||
324 | either "All", "Selected", "Files" or "Dirs"</para> | 323 | either <quote>All</quote>, <quote>Selected</quote>, <quote>Files</quote> or <quote>Dirs</quote></para> | ||
325 | </listitem> | 324 | </listitem> | ||
326 | </orderedlist> | 325 | </orderedlist> | ||
327 | </listitem> | 326 | </listitem> | ||
328 | <listitem> | 327 | <listitem> | ||
329 | <para> | 328 | <para> | ||
330 | <userinput>Filter</userinput> - replaced by the panel's filter | 329 | <userinput>Filter</userinput> - replaced by the panel's filter | ||
331 | mask</para> | 330 | mask</para> | ||
332 | </listitem> | 331 | </listitem> | ||
Show All 15 Lines | |||||
348 | </listitem> | 347 | </listitem> | ||
349 | <listitem> | 348 | <listitem> | ||
350 | <para> | 349 | <para> | ||
351 | <userinput>List</userinput> - replaced by a list of all | 350 | <userinput>List</userinput> - replaced by a list of all | ||
352 | <first parameter></para> | 351 | <first parameter></para> | ||
353 | <orderedlist> | 352 | <orderedlist> | ||
354 | <listitem> | 353 | <listitem> | ||
355 | <para>Parameter: Which items; | 354 | <para>Parameter: Which items; | ||
356 | either "All", "Selected", "Files" or "Dirs"</para> | 355 | either <quote>All</quote>, <quote>Selected</quote>, <quote>Files</quote> or <quote>Dirs</quote></para> | ||
357 | </listitem> | 356 | </listitem> | ||
358 | <listitem> | 357 | <listitem> | ||
359 | <para>Parameter (optional): | 358 | <para>Parameter (optional): | ||
360 | Separator between the items. | 359 | Separator between the items. | ||
361 | Default: | 360 | Default: | ||
362 | " "</para> | 361 | <quote> </quote></para> | ||
363 | </listitem> | 362 | </listitem> | ||
364 | <listitem> | 363 | <listitem> | ||
365 | <para>Parameter (optional): Omit the | 364 | <para>Parameter (optional): Omit the | ||
366 | current path. Default: no</para> | 365 | current path. Default: no</para> | ||
367 | </listitem> | 366 | </listitem> | ||
368 | <listitem> | 367 | <listitem> | ||
369 | <para>Parameter (optional): | 368 | <para>Parameter (optional): | ||
370 | Filtermask (for all but "Selected"). | 369 | Filtermask (for all but <quote>Selected</quote>). | ||
371 | Default: *</para> | 370 | Default: *</para> | ||
372 | </listitem> | 371 | </listitem> | ||
373 | <listitem> | 372 | <listitem> | ||
374 | <para>Parameter (optional): | 373 | <para>Parameter (optional): | ||
375 | Automatic escape spaces. Default: | 374 | Automatic escape spaces. Default: | ||
376 | yes</para> | 375 | yes</para> | ||
377 | </listitem> | 376 | </listitem> | ||
378 | </orderedlist> | 377 | </orderedlist> | ||
379 | </listitem> | 378 | </listitem> | ||
380 | <listitem> | 379 | <listitem> | ||
381 | <para> | 380 | <para> | ||
382 | <userinput>Select</userinput> - manipulates the selection in a | 381 | <userinput>Select</userinput> - manipulates the selection in a | ||
383 | panel</para> | 382 | panel</para> | ||
384 | <orderedlist> | 383 | <orderedlist> | ||
385 | <listitem> | 384 | <listitem> | ||
386 | <para>Parameter: Filtermask</para> | 385 | <para>Parameter: Filtermask</para> | ||
387 | </listitem> | 386 | </listitem> | ||
388 | <listitem> | 387 | <listitem> | ||
389 | <para>Parameter (optional): | 388 | <para>Parameter (optional): | ||
390 | manipulate in which way; either "Set", "Add" or "Remove". | 389 | manipulate in which way; either <quote>Set</quote>, <quote>Add</quote> or <quote>Remove</quote>. | ||
391 | Default: "Set"</para> | 390 | Default: <quote>Set</quote></para> | ||
392 | </listitem> | 391 | </listitem> | ||
393 | </orderedlist> | 392 | </orderedlist> | ||
394 | </listitem> | 393 | </listitem> | ||
395 | <listitem> | 394 | <listitem> | ||
396 | <para> | 395 | <para> | ||
397 | <userinput>Goto</userinput> - changes the panels' path to | 396 | <userinput>Goto</userinput> - changes the panels' path to | ||
398 | <first parameter></para> | 397 | <first parameter></para> | ||
399 | <orderedlist> | 398 | <orderedlist> | ||
400 | <listitem> | 399 | <listitem> | ||
401 | <para>Parameter: A relative or | 400 | <para>Parameter: A relative or | ||
402 | absolute path, or an URL</para> | 401 | absolute path, or an &URL;</para> | ||
403 | </listitem> | 402 | </listitem> | ||
404 | <listitem> | 403 | <listitem> | ||
405 | <para>Parameter (optional): Open the | 404 | <para>Parameter (optional): Open the | ||
406 | location in a new tab. Default: | 405 | location in a new tab. Default: | ||
407 | no</para> | 406 | no</para> | ||
408 | </listitem> | 407 | </listitem> | ||
409 | </orderedlist> | 408 | </orderedlist> | ||
410 | </listitem> | 409 | </listitem> | ||
Show All 19 Lines | |||||
430 | <listitem> | 429 | <listitem> | ||
431 | <para> | 430 | <para> | ||
432 | <userinput>Clipboard</userinput> - manipulates the | 431 | <userinput>Clipboard</userinput> - manipulates the | ||
433 | clipboard</para> | 432 | clipboard</para> | ||
434 | <orderedlist> | 433 | <orderedlist> | ||
435 | <listitem> | 434 | <listitem> | ||
436 | <para>Parameter: The text that | 435 | <para>Parameter: The text that | ||
437 | should go to the clipboard (you may want to use | 436 | should go to the clipboard (you may want to use | ||
438 | "%aCurrent%" here)</para> | 437 | <quote>%aCurrent%</quote> here)</para> | ||
439 | </listitem> | 438 | </listitem> | ||
440 | <listitem> | 439 | <listitem> | ||
441 | <para>Parameter (optional): Append | 440 | <para>Parameter (optional): Append | ||
442 | the text to the current content of the clipboard with | 441 | the text to the current content of the clipboard with | ||
443 | this separator</para> | 442 | this separator</para> | ||
444 | </listitem> | 443 | </listitem> | ||
445 | </orderedlist> | 444 | </orderedlist> | ||
446 | </listitem> | 445 | </listitem> | ||
▲ Show 20 Lines • Show All 114 Lines • ▼ Show 20 Line(s) | 550 | <listitem> | |||
561 | scripts/extensions. If all the needed files (normally | 560 | scripts/extensions. If all the needed files (normally | ||
562 | <filename>.js</filename> and maybe | 561 | <filename>.js</filename> and maybe | ||
563 | <filename>.ui</filename>) are in one of these dirs it is | 562 | <filename>.ui</filename>) are in one of these dirs it is | ||
564 | sufficient to give the file name only as <first parameter>. | 563 | sufficient to give the file name only as <first parameter>. | ||
565 | </para> | 564 | </para> | ||
566 | </listitem> | 565 | </listitem> | ||
567 | <listitem> | 566 | <listitem> | ||
568 | <para>Parameter (optional): a list | 567 | <para>Parameter (optional): a list | ||
569 | of variables which should be set, like "return=cmd; | 568 | of variables which should be set, like <quote>return=cmd; | ||
570 | a=lalala; b='%_Ask(..)'" so that the placeholder is | 569 | a=lalala; b='%_Ask(..)'</quote> so that the placeholder is | ||
571 | replaced be the content of the variable cmd and the other | 570 | replaced be the content of the variable cmd and the other | ||
572 | two have already these values when the script | 571 | two have already these values when the script | ||
573 | starts.</para> | 572 | starts.</para> | ||
574 | </listitem> | 573 | </listitem> | ||
575 | </orderedlist> | 574 | </orderedlist> | ||
576 | </listitem> | 575 | </listitem> | ||
577 | disabled due to KrJS does not compile (cannot find kjsembed from kdelibs --> | 576 | disabled due to KrJS does not compile (cannot find kjsembed from kdelibs --> | ||
578 | <listitem> | 577 | <listitem> | ||
Show All 9 Lines | |||||
588 | </listitem> | 587 | </listitem> | ||
589 | <listitem> | 588 | <listitem> | ||
590 | <para> | 589 | <para> | ||
591 | <userinput>ColSort</userinput> - set the sorting on a column | 590 | <userinput>ColSort</userinput> - set the sorting on a column | ||
592 | of a specific panel.</para> | 591 | of a specific panel.</para> | ||
593 | <orderedlist> | 592 | <orderedlist> | ||
594 | <listitem> | 593 | <listitem> | ||
595 | <para>Parameter: Column: Either | 594 | <para>Parameter: Column: Either | ||
596 | "Name", "Ext", "Type", "Size", "Modified", "Perms", | 595 | <quote>Name</quote>, <quote>Ext</quote>, <quote>Type</quote>, <quote>Size</quote>, <quote>Modified</quote>, <quote>Perms</quote>, | ||
597 | "rwx", "Owner" and "Group"</para> | 596 | <quote>rwx</quote>, <quote>Owner</quote> and <quote>Group</quote></para> | ||
598 | </listitem> | 597 | </listitem> | ||
599 | <listitem> | 598 | <listitem> | ||
600 | <para>Parameter: Sort sequence: | 599 | <para>Parameter: Sort sequence: | ||
601 | Either "Toggle", "Asc", "Desc"</para> | 600 | Either <quote>Toggle</quote>, <quote>Asc</quote>, <quote>Desc</quote></para> | ||
602 | </listitem> | 601 | </listitem> | ||
603 | </orderedlist> | 602 | </orderedlist> | ||
604 | </listitem> | 603 | </listitem> | ||
605 | <listitem> | 604 | <listitem> | ||
606 | <para> | 605 | <para> | ||
607 | <userinput>View</userinput> - set the view mode.</para> | 606 | <userinput>View</userinput> - set the view mode.</para> | ||
608 | <orderedlist> | 607 | <orderedlist> | ||
609 | <listitem> | 608 | <listitem> | ||
610 | <para>Parameter: View mode: Either | 609 | <para>Parameter: View mode: Either | ||
611 | "generic", "text", "hex"</para> | 610 | <quote>generic</quote>, <quote>text</quote>, <quote>hex</quote></para> | ||
612 | </listitem> | 611 | </listitem> | ||
613 | <listitem> | 612 | <listitem> | ||
614 | <para>Parameter: Window Mode: | 613 | <para>Parameter: Window Mode: | ||
615 | Either "tab", "window"</para> | 614 | Either <quote>tab</quote>, <quote>window</quote></para> | ||
616 | </listitem> | 615 | </listitem> | ||
617 | </orderedlist> | 616 | </orderedlist> | ||
618 | </listitem> | 617 | </listitem> | ||
619 | </itemizedlist> | 618 | </itemizedlist> | ||
620 | <para>A GUI-based helper for placeholder adding is | 619 | <para>A &GUI;-based helper for placeholder adding is | ||
621 | provided. Spaces in Path, Current and List are by default, | 620 | provided. Spaces in Path, Current and List are by default, | ||
622 | automatically escaped. There is one more important thing to know: | 621 | automatically escaped. There is one more important thing to know: | ||
623 | All placeholders that interact with &krusader; | 622 | All placeholders that interact with &krusader; | ||
624 | internal functions are called at expand time (meaning directly | 623 | internal functions are called at expand time (meaning directly | ||
625 | when the placeholders are replaced). External programs are | 624 | when the placeholders are replaced). External programs are | ||
626 | called at execution time (meaning after all placeholders are | 625 | called at execution time (meaning after all placeholders are | ||
627 | replaced).</para> | 626 | replaced).</para> | ||
628 | <para> | 627 | <para> | ||
629 | <emphasis role="bold">Advanced Properties</emphasis> | 628 | <emphasis role="bold">Advanced Properties</emphasis> | ||
630 | </para> | 629 | </para> | ||
631 | <para>Here you can configure where your command should be visible | 630 | <para>Here you can configure where your command should be visible | ||
632 | (for the right click menu). In addition, it is possible to change | 631 | (for the right click menu). In addition, it is possible to change | ||
633 | the command executed and confirm it separately. You can also set | 632 | the command executed and confirm it separately. You can also set | ||
634 | a user under which the command should be executed.</para> | 633 | a user under which the command should be executed.</para> | ||
635 | <itemizedlist> | 634 | <itemizedlist> | ||
636 | <listitem> | 635 | <listitem> | ||
637 | <para>Configures if the action is valid for a Protocol, Path, | 636 | <para>Configures if the action is valid for a Protocol, Path, | ||
638 | MIME type or File name.</para> | 637 | &MIME; type or File name.</para> | ||
639 | </listitem> | 638 | </listitem> | ||
640 | <listitem> | 639 | <listitem> | ||
641 | <para>Tweaking the command line before being executed.</para> | 640 | <para>Tweaking the command line before being executed.</para> | ||
642 | </listitem> | 641 | </listitem> | ||
643 | <listitem> | 642 | <listitem> | ||
644 | <para>Set a different user for the execution (this has no | 643 | <para>Set a different user for the execution (this has no | ||
645 | effect in &krusader; internal functions)</para> | 644 | effect in &krusader; internal functions)</para> | ||
646 | </listitem> | 645 | </listitem> | ||
647 | </itemizedlist> | 646 | </itemizedlist> | ||
648 | </sect1> | 647 | </sect1> |