Klang Quick Start Guide
Part I. Menu Functions
- File
- Open - Open a file. Any file may be opened, but opening a file of a supported file type will enable additional functionality.
- Close - Close a file
- Quit - Quit the program
- Note that there is no 'Save' function; all file writing happens immediately with no chance for undo; therefore you should back up all files first!
- Options
- Read-Only Mode Toggle this option on to disable all program functions that can alter a file. Useful for examining files without risk of alteration.
- Decimal Display In this mode, the program will display most numbers in decimal (base 10) form.
- Hex Display In this mode, the program will display most numbers in hex (base 6) form.
- Determine Text/Encoding Automatically In this mode, the program will try to figure out if unknown data is text or not, and it will try to figure out the encoding of the text itself. Only very common text encodings are supported using this method.
- Always Ask for Unknown Text Encoding - If a file contains unknown data, the user will be prompted to manually choose whether the data is text, and if it is text to pick an encoding. Any encoding supported by Java can be displayed.
- About
- Visit Website Opens a web browser to the Klang web site.
- Donate Opens a web browser to the Klang donation page.
- About Klang Editor Opens a dialog box with general information
Part II. Klang Main Window
- File Information - Contains basic information about the file
- Chunk Information - Contains basic information about the current chunk
- Raw File Access - Allows access to view and edit the file directly
- Chunk Hierarchy - Shows the chunk structure of the entire file in a tree-like view
- Chunk Data - Shows and edit data within the current chunk, and export, add, and delete chunks
Part III. File Information
This section of the window provides basic, file-level information. For some file types, additional information for the file will be disaplyed here as well (such as sample rate for an audio file, image size for images, etc.).
The 'Generate Checksum' button can be pressed to generate an MD5 checksum value for the file as a whole.
Part IV. Chunk Information
This section of the window provides information about the specific chunk that is currently being examined. Information about the chunk's name and type will be displayed, as well as information about the chunk's size and byte position.
The 'Start' and 'End' numbers refer to the actual start and end of the chunk within the file. This includes any chunk metadata, such as chunk name ('RIFF', 'DATA', etc.) and size info. The 'Data Start' and 'Data End' numbers refer to the start and stop positions of the actual chunk data itself, not including chunk metadata.
The 'Generate Checksum' button can be pressed to generate an MD5 checksum value for this chunk. Note that if the data portion of the chunk is smaller than the overall chunk, two checksums will be generated --- one for the overall chunk, and one for the data portion. This is to help confirm that the data in a chunk remains intact, even the chunk is renamed, or moved from one file to another.
Note that for unrecognized file types, the entire file will be placed into a single chunk of an unknown file type.
Part V. Raw File Access
This section of the window provides a way to view and edit any file, regardless of whether it is of a recognized file type. Note that any editing done in this portion of the window is RAW editing; it is quite possible to corrupt your file by editing values in this window!
Current Byte Displays the value of the current byte position. The buttons on either side allow you to move forwards and backwards in either 1 or 16 byte increments, and the 'Jump' button allows you to move directly to another byte position. Note the here, as in most other places in the interface, you can enter base-16 numbers by appending '0x' in front of your number (0xff, 0x1a, etc.).
Raw Hex and ASCII Display These two rows display the current byte, and the bytes surrounding it. For each row, the byte in red is the current byte. The 'Raw Hex' row always displays as hex value, regardless of other settings.
Current Position As... This section displays the value of the current byte as a variety of data types. For multi-byte values, the starting byte in the current byte. The 'Edit' button allows you to edit this value directly.
Insert, Delete, Export These buttons allow you to insert bytes (either from another file, or blank bytes), delete bytes, or export a range of bytes to another file.
Part VI. Chunk Hierarchy
This section of the window shows a hierarchical view of the file's chunks and allows you to navigate to a specific chunk or sub-chunk by clicking on it.
Part VII. Chunk Data
This section of the window allows you to interact with data on a chunk level. Actions taken within this section of the window will maintain the file's structural integrity without corruption. So, for instance, the deleting of a chunk will notify any parent chunks that the size of the chunk has changed.
- Export Export the current chunk. IMPORTANT: This function only exports the chunk data, not the extra metadata at the beginning or end of the chunk (chunk name, size, etc.).
- Delete Delete the current chunk.
- Edit Name Change the name of the current chunk. For most chunks, there will be certain restrictions on the new name (RIFF chunks must have 4 character ASCII names, for instance).
- Add Chunk Add a new chunk near the current chunk, either before, after, or in some cases under (as first child). You may insert a blank, empty chunk, or you may import chunk data from a file.
- Chunk Data Entries For some chunk types, there will be one or more chunk data entries. These represent specific data within the chunk. The 'Go' button will navigate the Raw File Access panel to display the data. The 'Edit' button allows editing the value directly.
