mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2026-09-28 17:11:11 -09:00
GP-5689 Add ByteViewer 'Chars' column
Convert the Ascii format to Chars, which supports decoding bytes using any available charset. Reworked the memory alignment option of the ByteViewer to allow the user to bump the displayed bytes left/right using an action. Add option to control how widely spaced the chars are displayed, to allow for wider non-Latin characters to be displayed correctly. Refactor the CharsetInfo class to better support the information needed by the new chars column. Fixed HexLongLong format to not mix BE / LE longs when constructing its final 16 byte value. Fixed handling of ByteViewer's background color to use its theme value.
This commit is contained in:
@@ -4,9 +4,9 @@
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
@@ -16,7 +16,6 @@
|
||||
package ghidra.app.plugin.core.debug.gui.memory;
|
||||
|
||||
import java.awt.Color;
|
||||
import java.awt.FontMetrics;
|
||||
import java.math.BigInteger;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
@@ -118,9 +117,8 @@ public class DebuggerMemoryByteViewerComponent extends ByteViewerComponent
|
||||
private final List<SelectionGenerator> selectionGenerators;
|
||||
|
||||
public DebuggerMemoryByteViewerComponent(DebuggerMemoryBytesPanel vpanel,
|
||||
ByteViewerLayoutModel layoutModel, DataFormatModel model, int bytesPerLine,
|
||||
FontMetrics fm) {
|
||||
super(vpanel, layoutModel, model, bytesPerLine, fm);
|
||||
ByteViewerLayoutModel layoutModel, DataFormatModel model, int bytesPerLine) {
|
||||
super(vpanel, layoutModel, model, bytesPerLine);
|
||||
// TODO: I don't care much for this reverse path
|
||||
this.panel = vpanel;
|
||||
|
||||
|
||||
@@ -4,9 +4,9 @@
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
@@ -37,6 +37,6 @@ public class DebuggerMemoryBytesPanel extends ByteViewerPanel {
|
||||
@Override
|
||||
protected ByteViewerComponent newByteViewerComponent(DataFormatModel model) {
|
||||
return new DebuggerMemoryByteViewerComponent(this, new ByteViewerLayoutModel(), model,
|
||||
getBytesPerLine(), getFontMetrics());
|
||||
getBytesPerLine());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user