mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-07-18 05:38:14 +00:00
Fixed Script editors - tab size now matches indent size
This commit is contained in:
@@ -4,6 +4,7 @@ All notable changes to this project will be documented in this file.
|
||||
## [Unreleased]
|
||||
### Fixed
|
||||
- [#2021], [#2000] Caret position in editors when using tabs and / or unicode
|
||||
- Script editors - tab size now matches indent size
|
||||
|
||||
## [20.0.0] - 2023-11-05
|
||||
### Added
|
||||
|
||||
@@ -376,7 +376,7 @@ public class ASMSourceEditorPane extends DebuggableEditorPane implements CaretLi
|
||||
}
|
||||
|
||||
super.setText(highlightedText.text);
|
||||
setCaretPosition(0);
|
||||
setCaretPosition(0);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -36,6 +36,7 @@ import javax.swing.text.BadLocationException;
|
||||
import javax.swing.text.Document;
|
||||
import javax.swing.text.EditorKit;
|
||||
import javax.swing.text.JTextComponent;
|
||||
import javax.swing.text.PlainDocument;
|
||||
import jsyntaxpane.SyntaxDocument;
|
||||
|
||||
/**
|
||||
@@ -162,6 +163,8 @@ public class UndoFixedEditorPane extends JEditorPane {
|
||||
((SyntaxDocument) doc).setIgnoreUpdate(false);
|
||||
}
|
||||
|
||||
doc.putProperty(PlainDocument.tabSizeAttribute, Configuration.indentSize.get());
|
||||
|
||||
setDocument(doc);
|
||||
} catch (BadLocationException | IOException ex) {
|
||||
Logger.getLogger(UndoFixedEditorPane.class.getName()).log(Level.SEVERE, null, ex);
|
||||
|
||||
Reference in New Issue
Block a user