Posted by: pspad | Date: 03/06/2017 13:41 | IP: IP Logged
Freeman:When possibility to pass encoding exists, I vote for any encoding, passing with data, as in HTTP. With UTF-8, Russian texts become ~1.5 times longer, in bytes. The same thing with other languages use Cyrillic.
I am trying to prevent situation when somebody uses Cyrillic in ANSI file. The file become unreadable.
Same thing if you name script items in Cyrillic and you will run it on Windows with English regional settings - menu items will be broken.
UTF-8 make files 1,5 longer, UTF-16 2x longer always.
Posted by: Freeman | Date: 03/06/2017 14:19 | IP: IP Logged
pspad:Same thing if you name script items in Cyrillic and you will run it on Windows with English regional settings - menu items will be broken.
The first question, do scripts have encoding tag, like <meta charset> in HTML? If not, UTF-8 is prefered, I will not vote contra.
But, in localization files, you can set encoding manually, if appropriate setting exists in the format, like:
Other tip for encodings is treat manually given encoding as fallback encoding. First, try to interpret file/script as UTF-8 and then, if failed, use fallback encoding or default ANSI encoding when fallback encoding is not given. I call this behavior "browser-like".
But, if you want to prevent abracadabra on Western localizations, require UTF-8 for all scripts. In this case, when PSPad cannot decode script as UTF-8, it should display an error.
Posted by: vbr | Date: 03/06/2017 14:27 | IP: IP Logged
pspad:Which encoding choose to store PSPad files?
Localization files, scripts, clips, e.t.c.
I vote for UTF-8.
Localization files are now stored in UTF-8
Scripts can be in UTF-8 as well
In this case we need to store files in different folders from PSPad 4.x to prevent mix of ANSI and UNICODE encoding.
Do you have any idea how to choose name for new folders? Any prefix or suffix?
Good news is I have scripting in version 5
I'd vote for utf-8 for internal configuration files scripts etc. too.
It is good, that PSPad can handle non-unicode text in many encodings, but for such internal data, utf-8 seems to be the obvious option.
I believe, that for the overall size of these files, the amount of data is still reasonable in utf-8, while it would avoid most compatibility problems.
I personally don't really like prefixed or suffixed directory names in such cases and would prefer the longer meaningful names as proposed, but it is a minor problem either way.
If such folders appear next to each other, it will look rather confusing in any case, which is probably ok, as it indicates the redundancy.
A clean program folder with the configuration, script, clips... files will not need both versions, right?
Thanks for adding the scripting support!
Posted by: Stefan | Date: 03/06/2017 14:52 | IP: IP Logged
We can rename folders
Oh, you mean all folders, I missed that.
Then I would vote for a whole "\Unicode\" folder
with the same folders and same names as now
That way we would be "continuous".
PSPad would check if Unicode folder exists,
IF YES use configuration from there,
IF NOT, see if files in config folders in the root of the PSPad folder
has a BOM, and if yes, use that files.
Advantage: in a few years we can get rid of the
whole UNICODE folder and use the old (ANSI) folders again.
Posted by: Freeman | Date: 03/06/2017 15:02 | IP: IP Logged
vbr:I personally don't really like prefixed or suffixed directory names in such cases
Jan, in addition to UTF-8 autodetection, you may add an option for old scripts: reject (display error) or use in compatibility mode (with same issues as in PSPad 4).
Posted by: Ilya | Date: 03/06/2017 16:22 | IP: IP Logged
One additional problem: "Open file" opens the "Desktop" folder instead of already opened file's folder, as it was in version 4.
Posted by: Stefan | Date: 03/06/2017 16:33 | IP: IP Logged
Ilya:One additional problem: "Open file" opens the "Desktop" folder instead of already opened file's folder, as it was in version 4.
Have you checked
the Program Settings... > Files and Dirs >
(o) Remember Last Directory
(_) Same As Active Document
(_) Designate Directory
Stefan (pleased user since 1722)
Do you know you can spend Jan a beer? (click here)
Inofficial FAQs + Infos + Special Settings
Posted by: pspad | Date: 03/06/2017 18:54 | IP: IP Logged
Batch CP convertor tool
I am finishing batch CP convertor tool.
What is the best place (menu placement) for this tool? Where you would look for it intuitively?
Edited 1 time(s). Last edit at 03/06/2017 18:56 by pspad.
Posted by: khagaroth | Date: 03/06/2017 19:10 | IP: IP Logged
Hmm, it's a tough choice between Encoding and Tools menu. Probably Tools.
Posted by: pspad | Date: 03/06/2017 19:15 | IP: IP Logged
khagaroth:Hmm, it's a tough choice between Encoding and Tools menu. Probably Tools.
Just now is it in the tool menu. But Encoding menu is maybe better solution.
Edited 1 time(s). Last edit at 03/06/2017 19:16 by pspad.