diff --git a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/configuration/Configuration.java b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/configuration/Configuration.java index a13dd53b1..d1a5d921a 100644 --- a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/configuration/Configuration.java +++ b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/configuration/Configuration.java @@ -93,6 +93,10 @@ public class Configuration { @ConfigurationCategory("display") public static final ConfigurationItem useHexColorFormat = null; + @ConfigurationDefaultBoolean(false) + @ConfigurationCategory("display") + public static final ConfigurationItem showOldTextDuringTextEditing = null; + @ConfigurationDefaultBoolean(false) @ConfigurationCategory("ui") public static final ConfigurationItem gotoMainClassOnStartup = null; diff --git a/src/com/jpexs/decompiler/flash/gui/ImagePanel.java b/src/com/jpexs/decompiler/flash/gui/ImagePanel.java index 1cbe021fd..bceb053dd 100644 --- a/src/com/jpexs/decompiler/flash/gui/ImagePanel.java +++ b/src/com/jpexs/decompiler/flash/gui/ImagePanel.java @@ -169,7 +169,7 @@ public final class ImagePanel extends JPanel implements ActionListener, MediaDis w = w2; } } - + rect = new Rectangle(getWidth() / 2 - w / 2, getHeight() / 2 - h / 2, w, h); } else { rect = null; @@ -565,24 +565,19 @@ public final class ImagePanel extends JPanel implements ActionListener, MediaDis textTag.toImage(0, 0, 0, null, 0, image, m, new ColorTransform() { @Override - public int getBlueAdd() { - return 192; + public int apply(int color) { + return 0xFFC0C0C0; } - - @Override - public int getGreenAdd() { - return 192; - } - - @Override - public int getRedAdd() { - return 192; - } - }); if (newTextTag != null) { - newTextTag.toImage(0, 0, 0, null, 0, image, m, new ColorTransform()); + newTextTag.toImage(0, 0, 0, null, 0, image, m, new ColorTransform() { + + @Override + public int apply(int color) { + return 0xFF000000; + } + }); } iconPanel.setImg(image); diff --git a/src/com/jpexs/decompiler/flash/gui/TextPanel.java b/src/com/jpexs/decompiler/flash/gui/TextPanel.java index 55b3fdb92..b680c6d80 100644 --- a/src/com/jpexs/decompiler/flash/gui/TextPanel.java +++ b/src/com/jpexs/decompiler/flash/gui/TextPanel.java @@ -16,6 +16,7 @@ */ package com.jpexs.decompiler.flash.gui; +import com.jpexs.decompiler.flash.configuration.Configuration; import com.jpexs.decompiler.flash.gui.abc.LineMarkedEditorPane; import com.jpexs.decompiler.flash.tags.base.FontTag; import com.jpexs.decompiler.flash.tags.base.MissingCharacterHandler; @@ -164,6 +165,10 @@ public class TextPanel extends JPanel implements ActionListener { } private void textChanged() { + if (!Configuration.showOldTextDuringTextEditing.get()) { + return; + } + if (textValue.isEditable()) { TreeItem item = mainPanel.tagTree.getCurrentTreeItem(); if (item instanceof TextTag) { diff --git a/src/com/jpexs/decompiler/flash/gui/locales/AdvancedSettingsDialog.properties b/src/com/jpexs/decompiler/flash/gui/locales/AdvancedSettingsDialog.properties index 1f50b84ca..c059c6b06 100644 --- a/src/com/jpexs/decompiler/flash/gui/locales/AdvancedSettingsDialog.properties +++ b/src/com/jpexs/decompiler/flash/gui/locales/AdvancedSettingsDialog.properties @@ -296,3 +296,6 @@ config.description.autoLoadEmbeddedSwfs = Automaticaly load the embedded SWFs fr config.name.overrideTextExportFileName = Override text export filename config.description.overrideTextExportFileName = You can customite the filename of the expoted text. Use {filename} placeholder to use the filename of current SWF. + +config.name.showOldTextDuringTextEditing = Show old text during text editing +config.description.showOldTextDuringTextEditing = Shows the original text of the text tag with gray color in the preview area. diff --git a/src/com/jpexs/decompiler/flash/gui/locales/AdvancedSettingsDialog_hu.properties b/src/com/jpexs/decompiler/flash/gui/locales/AdvancedSettingsDialog_hu.properties index 37a1b48f5..f53c91e8c 100644 --- a/src/com/jpexs/decompiler/flash/gui/locales/AdvancedSettingsDialog_hu.properties +++ b/src/com/jpexs/decompiler/flash/gui/locales/AdvancedSettingsDialog_hu.properties @@ -293,3 +293,9 @@ config.description.tagTreeShowEmptyFolders = \u00dcres mapp\u00e1k mutat\u00e1sa config.name.autoLoadEmbeddedSwfs = Be\u00e1gyazott SWFek automatikus bet\u00f6lt\u00e9se config.description.autoLoadEmbeddedSwfs = Aut\u00f3matikusan bet\u00f6lti a be\u00e1gyazott SWF-eket a DefineBinaryData tagekb\u0151l. + +config.name.overrideTextExportFileName = Sz\u00f6veg export\u00e1l\u00e1s f\u00e1jlnev\u00e9nek fel\u00fcl\u00edr\u00e1sa +config.description.overrideTextExportFileName = Szem\u00e9lyre szabhatod a nev\u00e9t az export\u00e1lt sz\u00f6vegf\u00e1jlnak. Haszn\u00e1ld a {filename} helykit\u00f6lt\u0151t az aktu\u00e1lis SWF nev\u00e9hez. + +config.name.showOldTextDuringTextEditing = R\u00e9gi sz\u00f6veg mutat\u00e1sa sz\u00f6veg szerkeszt\u00e9sekor +config.description.showOldTextDuringTextEditing = Mutatja az eredeti sz\u00f6veget sz\u00fcrke sz\u00ednnel az el\u0151n\u00e9zeti ablakban szerkeszt\u00e9s k\u00f6zben.