diff --git a/CHANGELOG.md b/CHANGELOG.md index 387a23d72..5c73073dc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,7 @@ All notable changes to this project will be documented in this file. ### Added - StartSound and StartSound2 show characterId/class in the tag tree - Folder preview for sounds +- [#2176] Ignoring letter spacing on text search (only applies to global search, not to search inside text) ### Fixed - Debugger - getting children of top level variables @@ -17,6 +18,7 @@ All notable changes to this project will be documented in this file. - [#2175] Removing DefineButtonSound, warning about incorrect sound character type in FLA export - [#2175] FLA Export - exporting 320kbps MP3s as 160kbps - [#2178] Undo on sprites +- [#2176] Reset letterspacing on text import ## [20.1.0] - 2023-12-30 ### Added @@ -3363,6 +3365,7 @@ Major version of SWF to XML export changed to 2. [alpha 9]: https://github.com/jindrapetrik/jpexs-decompiler/compare/alpha8...alpha9 [alpha 8]: https://github.com/jindrapetrik/jpexs-decompiler/compare/alpha7...alpha8 [alpha 7]: https://github.com/jindrapetrik/jpexs-decompiler/releases/tag/alpha7 +[#2176]: https://www.free-decompiler.com/flash/issues/2176 [#2149]: https://www.free-decompiler.com/flash/issues/2149 [#2172]: https://www.free-decompiler.com/flash/issues/2172 [#2174]: https://www.free-decompiler.com/flash/issues/2174 diff --git a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/tags/base/StaticTextTag.java b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/tags/base/StaticTextTag.java index 489edf03f..50c60eddc 100644 --- a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/tags/base/StaticTextTag.java +++ b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/tags/base/StaticTextTag.java @@ -302,7 +302,7 @@ public abstract class StaticTextTag extends TextTag { } int advance = getAdvance(fnt, ge.glyphIndex, textHeight, c, nextChar); int delta = ge.glyphAdvance - advance; - if (delta != letterSpacing) { + if (delta != letterSpacing && !ignoreLetterSpacing) { writer.append("[space " + (delta - letterSpacing) + "]"); } } diff --git a/src/com/jpexs/decompiler/flash/gui/MainPanel.java b/src/com/jpexs/decompiler/flash/gui/MainPanel.java index 20f3d6a49..c51043562 100644 --- a/src/com/jpexs/decompiler/flash/gui/MainPanel.java +++ b/src/com/jpexs/decompiler/flash/gui/MainPanel.java @@ -2973,7 +2973,7 @@ public final class MainPanel extends JPanel implements TreeSelectionListener, Se boolean ignoreCase = searchDialog.ignoreCaseCheckBox.isSelected(); boolean regexp = searchDialog.regexpCheckBox.isSelected(); - + boolean scriptSearch = searchDialog.searchInASRadioButton.isSelected() || searchDialog.searchInPCodeRadioButton.isSelected(); if (scriptSearch) { @@ -3144,7 +3144,7 @@ public final class MainPanel extends JPanel implements TreeSelectionListener, Se for (Tag tag : swf.getTags()) { if (tag instanceof TextTag) { TextTag textTag = (TextTag) tag; - if (pat.matcher(textTag.getFormattedText(false).text).find()) { + if (pat.matcher(textTag.getFormattedText(true).text).find()) { found.add(textTag); } }