Xfce Wiki

Sub domains
 

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
xfce:xfce4-appfinder:preferences [2019/04/09 21:59]
blueberrybrownie [Custom Actions]
xfce:xfce4-appfinder:preferences [2019/04/09 22:20] (current)
blueberrybrownie [Usage]
Line 46: Line 46:
  
 ==== Usage ==== ==== Usage ====
 +You can add a new (empty) action by clicking on the {gui>​Add} (+) button and remove the selected action by pressing the {gui>​Delete} (x) button. You can edit an existing action by selecting it from the list and using the {gui>​Type},​ {gui>​Pattern} and {gui>​Command} fields.
  
-You can add a new (empty) action by clicking on the {gui>​Add} (+) button and remove the selected action by pressing the {gui>​Delete} (x) button.+? Type 
 +! There are two types of pattern matches:
  
-Strings in the Application Finder by the {gui>​type} and {gui>​pattern} or the action. If there is a match, the {gui>​command} is executed as a replacement for the entered string. +  * **Prefix** - if this type is selected, there is a match if the entered string starts with the pattern ​specified
- +  ​* **Regular Expression** - For complex matches you can write a [[https://​en.wikipedia.org/​wiki/​Perl_Compatible_Regular_Expressions|Perl-compatible regular expression]] that'​s ​matched against the entered string.
-? Type +
-! There are two types of pattern matches. +
-  ? Prefix +
-  ! If this type is selected, there is a match if the entered string starts with {gui>pattern}+
-  ​Regular Expression +
-  ! For complex matches you can write a [[https://​en.wikipedia.org/​wiki/​Perl_Compatible_Regular_Expressions|Perl-compatible regular expression]] that is matched against the entered string.+
 ? Pattern ? Pattern
-! Depending on the selected {gui>typeit will describe ​the matching ​prefix or regular expression.+! Depending on the type selected, ​it describes ​the prefix or regular expression.
 ? Command ? Command
-! The command that is executed when the pattern is matched. To include ​(partsof the match the following variables are available:+! The command that is executed when the pattern is matched. To include parts of the search in the command ​the following variables are available:
   ? Prefix   ? Prefix
-    ? %s +  ! **%s** - Include the string after the matched pattern. ​For example, ​if the prefix-pattern is ''​abc''​ and the entered command ​is ''​abcdef'',​ ''​%s''​ will be replaced with ''​def''​. 
-    ! Include the string after the matched pattern. ​So if the prefix-pattern is ''​abc''​ and the entered command ''​abcdef'',​ ''​%s''​ will be replaced with ''​def''​. +  ! **%S** - Include the complete string after the matched ​pattern. ​For example, ​if the prefix-pattern is ''​abc''​ and the entered command ​is ''​abcdef'',​ ''​%s''​ will be replaced with ''​abcdef''​.
-    ? ​%S +
-    ! Include the complete string after the matches ​pattern. ​So if the prefix-pattern is ''​abc''​ and the entered command ''​abcdef'',​ ''​%s''​ will be replaced with ''​abcdef''​.+
   ? Regular Expression   ? Regular Expression
-  ! During the process of matching, the match results of subpattern ​between parentheses ''​( )''​ are recorded for later use. ''​\''​ plus a number to refer to the corresponding ​substring. ''​\1''​ refers to 1st pair of parentheses'​ match result, ''​\2''​ refers to 2nd pair of parentheses'​ match result. A special case is ''​\0''​ which will be replaced with the entire match. +  ! During the process of matching, the results of the sub-pattern ​between parentheses ''​( )''​ are recorded for later use. ''​\''​ plus a number to refers ​to the corresponding ​sub-stringFor instance, ​''​\1''​ refers to the 1st pair of parentheses'​ match result, ​while ''​\2''​ refers to 2nd pair of parentheses'​ match result. A special case is ''​\0''​which will be replaced with the entire match. 
-  ! If the pattern is ''​^ab(.*)fg$''​ and the entered command ''​abcdefg'',​ ''​\1''​ will be replaced with ''​cde''​.+  ! If the pattern is ''​^ab(.*)fg$''​ and the entered command ''​abcdefg'' ​for example, ''​\1''​ will be replaced with ''​cde''​. 
 +? Save match in command history 
 +! Select this option if you want matches to be saved in the {gui>​Commands History} category. 
   ​   ​