102 <p> |
102 <p> |
103 When HexEditWidget loads data, HexEditChunks access them using a QIODevice |
103 When HexEditWidget loads data, HexEditChunks access them using a QIODevice |
104 interface. When the app uses a QByteArray or Python bytearray interface, |
104 interface. When the app uses a QByteArray or Python bytearray interface, |
105 QBuffer is used to provide again a QIODevice like interface. No data will |
105 QBuffer is used to provide again a QIODevice like interface. No data will |
106 be changed, therefore HexEditChunks opens the QIODevice in |
106 be changed, therefore HexEditChunks opens the QIODevice in |
107 QIODevice.ReadOnly mode. After every access HexEditChunks closes the |
107 QIODevice.OpenModeFlag.ReadOnly mode. After every access HexEditChunks |
108 QIODevice. That's why external applications can overwrite files while |
108 closes the QIODevice. That's why external applications can overwrite |
109 HexEditWidget shows them. |
109 files while HexEditWidget shows them. |
110 </p> |
110 </p> |
111 <p> |
111 <p> |
112 When the the user starts to edit the data, HexEditChunks creates a local |
112 When the the user starts to edit the data, HexEditChunks creates a local |
113 copy of a chunk of data (4 kilobytes) and notes all changes there. Parallel |
113 copy of a chunk of data (4 kilobytes) and notes all changes there. Parallel |
114 to that chunk, there is a second chunk, which keeps track of which bytes |
114 to that chunk, there is a second chunk, which keeps track of which bytes |