<!--
Please provide as much information as possible about what your PR aims
to do.
PRs with no description will most likely be closed until more
information is provided.
If you're planing on changing fundamental behaviour or add big new
features, please open a GitHub Issue first before starting to work on
it.
If it's not something big and you still want to contact us about it,
feel free to do so !
-->
### Problem description
<!-- Describe the bug that you fixed/feature request that you
implemented, or link to an existing issue describing it -->
Implement a Linux backend for the ProcessMemoryProvider plugin.
### Implementation description
<!-- Explain what you did to correct the problem -->
Most of the provider code is the same between Windows and Linux. The
primary differences are:
- enumerate PIDs in `/proc/` to get the process list
- use `/proc/<PID>/cmdline` as the process name
- parse `/proc/<PID>/maps` to get the module list
- reading/writing from memory is done using
`process_vm_readv`/`process_vm_writev`
NOTE: `sudo setcap CAP_SYS_PTRACE=+eip build/imhex` must be run to give
the binary permission to read another process' memory. Running as root
user should also work but I would not recommend it.
### Additional things
The existing translations keys no longer match since I moved the plugin
from `windows` to `builtin`.
I'm not well versed in C++ so I attempted to keep my changes rather
simple. Feedback is very welcome.
---------
Co-authored-by: WerWolv <werwolv98@gmail.com>
### Implementation description
I synchronized the json key order with `en_US.json` in each lang file.
### Additional things
Here are simple python script that make this change
```python
import json
from collections import OrderedDict
original = "./en_US.json"
modified = [
"./de_DE.json",
"./es_ES.json",
"./it_IT.json",
"./ja_JP.json",
"./ko_KR.json",
"./pt_BR.json",
"./zh_CN.json",
"./zh_TW.json",
]
for modify in modified:
dict_2 = {}
with open(original, 'r', encoding='utf-8') as f1, open(modify, 'r', encoding='utf-8') as f2:
dict_1 = json.load(f1)
dict_2 = json.load(f2)
dict_1_translations = dict_1["translations"]
dict_2_translations = dict_2["translations"]
ordered_dict_2 = OrderedDict((k, dict_2_translations[k]) for k in dict_1_translations.keys())
dict_2["translations"] = ordered_dict_2
with open(modify, 'w', encoding='utf-8') as f2:
json.dump(dict_2, f2, ensure_ascii=False, indent=4)
```
<!--
Please provide as much information as possible about what your PR aims
to do.
PRs with no description will most likely be closed until more
information is provided.
If you're planing on changing fundamental behaviour or add big new
features, please open a GitHub Issue first before starting to work on
it.
If it's not something big and you still want to contact us about it,
feel free to do so !
-->
### Problem description
### Implementation description
Updated Traditional Chinese (Taiwan) translations for ImHex.
### Screenshots
<!-- If your change is visual, take a screenshot showing it. Ideally,
make before/after sceenshots -->
### Additional things
<!-- Anything else you would like to say -->
<!--
Please provide as much information as possible about what your PR aims
to do.
PRs with no description will most likely be closed until more
information is provided.
If you're planing on changing fundamental behaviour or add big new
features, please open a GitHub Issue first before starting to work on
it.
If it's not something big and you still want to contact us about it,
feel free to do so !
-->
### Problem description
<!-- Describe the bug that you fixed/feature request that you
implemented, or link to an existing issue describing it -->
see #723
### Implementation description
<!-- Explain what you did to correct the problem -->
`xdg-desktop-portal-wlr` is not relevant because it does not provide the
FileChooser interface.
`xdg-desktop-portal` needs the `WAYLAND_DISPLAY` env var on wayland and
the `DISPLAY` and `XAUTHORITY` env vars on xorg. If the dbus user
session bus is not run in a way that it already gets those variables,
they must be given via `dbus-update-activation-environment(1)`.
### Screenshots
<!-- If your change is visual, take a screenshot showing it. Ideally,
make before/after sceenshots -->
### Additional things
<!-- Anything else you would like to say -->
fixes#723
I just realized one feature request existed about this tool and have
added a comment to it referring this pr. Errors and additions are
described in the fork commit already. I'm not sure if I should repeat
them here again. I have tested the changes thoroughly, but it is always
possible some fringe case was not tested and is incorrect. The tests
were done using the many similar online calculators for IEEE 754
floating point formats.
IEEE 745 floating point tool redesign modeled after 'float toy' web app
(http://evanw.github.io/float-toy/)
Streamlined output using colors and compact layout which can be further
simplified.
Chosen display mode (detailed or simplified) is automatically saved and
set on new sessions.
Edit the binary bits, the integer hexadecimal or the floating point
decimal values and the entire app will update with the change.
Supports the main IEEE745 standard formats (half, single and double
precision) together with custom formats of size <= 64 bits.
Each format choice uses and displays the number of significant decimal
digits defined by the mantissa size.
Added labels to identify the location of each bit box inside the binary
representation.
Satisfies round trip / idempotent (reproducing) conversion property
Added theme colors, radio buttons for display mode and a clear button
that resets the tool.
Removed previously and incorrectly added locale translation to various
labels and languages
Attempted to adhere to code style formatting using existing code as
example.
An effort was made to use preferred variable types and functions from
std namespace when appropriate.
Attempted to document code using comments.
Not implemented / left to complete at an later time
Arbitrary width and precision formats.
Extended precision formats.
Shortest string property.
hexadecimal floating point display and conversions.