Bug #3288

Text editor, 'Execute script' command doesn't work

Ajouté par Serge Heiden il y a environ 3 ans. Mis à jour il y a plus d'un an.

Statut:New Début:30/09/2022
Priorité:Normal Echéance:
Assigné à:- % réalisé:

70%

Catégorie:Commands Temps passé: -
Version cible:TXM 0.8.4

Description

In a text editor opened on a .groovy file, the command does nothing and no error message.

The 'Execute text selection' works.

Solution

- fix the silent NPE before calling the Groovy Script Engine
- use the GroovyShell.execute() method instead of the GroovyScriptEngine.createScript() method. The lastest needs the script to be in the root directory (TXMHOME/scripts/groovy/user)

Historique

#1 Mis à jour par Matthieu Decorde il y a presque 3 ans

  • Description mis à jour (diff)
  • % réalisé changé de 0 à 70

#2 Mis à jour par Matthieu Decorde il y a plus de 2 ans

  • Version cible changé de TXM 0.8.2 à TXM 0.8.3

#3 Mis à jour par Sebastien Jacquot il y a plus d'un an

  • Version cible changé de TXM 0.8.3 à TXM 0.8.4

Formats disponibles : Atom PDF