Menu

#1300 Integrate ExternalFinder plugin, add configuration GUI

4.1
closed-fixed
None
5
2022-07-24
2017-01-04
No

The ExternalFinder plugin is now integrated with OmegaT. Big thanks to Chihiro Hio for creating the plugin and agreeing to license the code under GPLv3.

The plugin is integrated almost as-is, based on commit 3cd27b5; the only user-facing differences are:

  • For consistency with other project-specific configuration files, the ExternalFinder project-specific finder.xml is now located in the project's omegat folder rather than the root.
  • To specify a mnemonic for invoking an ExternalFinder item, prefix the desired character with & rather than _. In XML this should be escaped to &.
  • After replacing the {target} token in a URL, the resulting URL must be a valid URI per the Java spec. This is stricter than the plugin, which (apparently) allowed e.g. spaces to appear in the URL template. Now such characters must be appropriately escaped: + or %20 for a space, etc. Effectively this means that encoding="none" cannot be used with URLs.

With this integration comes a new GUI for configuring both global settings (Preferences > External Search) and project-specific settings (Project Properties > External Search).

See the org.omegat.externalfinder package info (omegat.sourceforge.io) for details on the XML format.

Invalid finder.xml definitions are reported in the OmegaT log; relevant messages are prefixed with "ExternalFinder".

Related

Feature Requests: #1303
Feature Requests: #1304

Discussion

  • Didier Briel

    Didier Briel - 2017-01-04

    In addition to being able to copy finder.xml to the /omegat folder of a project, it is also possible to add project-specific URLs to a project, using the External Search button in the project properties.

    From Aaron:

    Unlike segmentation or filters where either the global config is used or the project config is used, with ExternalFinder items the global and project configs are combined on the fly, with project items overriding global items based on name. Thus there is no need to copy the global config when editing the project config. The project config file will be deleted if present if you remove all items.

    Didier

     
  • Héctor Cartagena

    Brilliant!

     
  • Didier Briel

    Didier Briel - 2017-01-09
    • status: open-fixed --> closed-fixed
    • Group: 4.0 --> 4.1
     
  • Didier Briel

    Didier Briel - 2017-01-09

    Implemented in the released version 4.1 of OmegaT.

    Didier

     
  • Aaron Madlon-Kay

    • Description has changed:

    Diff:

    --- old
    +++ new
    @@ -4,6 +4,7 @@
    
    
     - For consistency with other project-specific configuration files, the ExternalFinder project-specific `finder.xml` is now located in the project's `omegat` folder rather than the root.
     - To specify a mnemonic for invoking an ExternalFinder item, prefix the desired character with `&` rather than `_`. In XML this should be escaped to `&`.
    +- After replacing the `{target}` token in a URL, the resulting URL must be a valid URI per the [Java spec](https://docs.oracle.com/javase/8/docs/api/java/net/URI.html#URI-java.lang.String-). This is stricter than the plugin, which (apparently) allowed e.g. spaces to appear in the URL template. Now such characters must be appropriately escaped: `+` or `%20` for a space, etc.
    
     With this integration comes a new GUI for configuring both global settings (Preferences > External Search) and project-specific settings (Project Properties > External Search).
    
     
  • Aaron Madlon-Kay

    • Description has changed:

    Diff:

    --- old
    +++ new
    @@ -4,7 +4,7 @@
    
    
     - For consistency with other project-specific configuration files, the ExternalFinder project-specific `finder.xml` is now located in the project's `omegat` folder rather than the root.
     - To specify a mnemonic for invoking an ExternalFinder item, prefix the desired character with `&` rather than `_`. In XML this should be escaped to `&`.
    -- After replacing the `{target}` token in a URL, the resulting URL must be a valid URI per the [Java spec](https://docs.oracle.com/javase/8/docs/api/java/net/URI.html#URI-java.lang.String-). This is stricter than the plugin, which (apparently) allowed e.g. spaces to appear in the URL template. Now such characters must be appropriately escaped: `+` or `%20` for a space, etc.
    +- After replacing the `{target}` token in a URL, the resulting URL must be a valid URI per the [Java spec](https://docs.oracle.com/javase/8/docs/api/java/net/URI.html#URI-java.lang.String-). This is stricter than the plugin, which (apparently) allowed e.g. spaces to appear in the URL template. Now such characters must be appropriately escaped: `+` or `%20` for a space, etc. Effectively this means that `encoding="none"` cannot be used with URLs.
    
     With this integration comes a new GUI for configuring both global settings (Preferences > External Search) and project-specific settings (Project Properties > External Search).
    
     
  • Aaron Madlon-Kay

    • Description has changed:

    Diff:

    --- old
    +++ new
    @@ -9,3 +9,5 @@
     With this integration comes a new GUI for configuring both global settings (Preferences > External Search) and project-specific settings (Project Properties > External Search).
    
     See the [org.omegat.externalfinder package info](https://omegat.ci.cloudbees.com/job/omegat-trunk/javadoc/org/omegat/externalfinder/package-summary.html) for details on the XML format.
    +
    +Invalid `finder.xml` definitions are reported in the OmegaT log; relevant messages are prefixed with "ExternalFinder".
    
     
  • Jean-Christophe Helary

    • Description has changed:

    Diff:

    --- old
    +++ new
    @@ -8,6 +8,6 @@
    
     With this integration comes a new GUI for configuring both global settings (Preferences > External Search) and project-specific settings (Project Properties > External Search).
    
    -See the [org.omegat.externalfinder package info](https://omegat.ci.cloudbees.com/job/omegat-trunk/javadoc/org/omegat/externalfinder/package-summary.html) for details on the XML format.
    +See the [org.omegat.externalfinder package info](https://omegat.sourceforge.io/javadoc-latest/org/omegat/externalfinder/package-summary.html) for details on the XML format.
    
     Invalid `finder.xml` definitions are reported in the OmegaT log; relevant messages are prefixed with "ExternalFinder".
    
     

Log in to post a comment.

MongoDB Logo MongoDB