-
-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add encoding setting #1203
Add encoding setting #1203
Conversation
CodeEdit/Features/AppPreferences/Model/Text Editing/TextEditingPreferences.swift
Outdated
Show resolved
Hide resolved
CodeEdit/Features/AppPreferences/Model/Text Editing/TextEditingPreferences.swift
Outdated
Show resolved
Hide resolved
...dit/Features/AppPreferences/Sections/TextEditingPreferences/TextEditingPreferencesView.swift
Outdated
Show resolved
Hide resolved
...dit/Features/AppPreferences/Sections/TextEditingPreferences/TextEditingPreferencesView.swift
Outdated
Show resolved
Hide resolved
...dit/Features/AppPreferences/Sections/TextEditingPreferences/TextEditingPreferencesView.swift
Outdated
Show resolved
Hide resolved
CodeEdit/Features/AppPreferences/Model/Text Editing/TextEditingPreferences.swift
Outdated
Show resolved
Hide resolved
CodeEdit/Features/AppPreferences/Model/Text Editing/TextEditingPreferences.swift
Outdated
Show resolved
Hide resolved
CodeEdit/Features/AppPreferences/Model/Text Editing/TextEditingPreferences.swift
Outdated
Show resolved
Hide resolved
CodeEdit/Features/AppPreferences/Model/Text Editing/TextEditingPreferences.swift
Outdated
Show resolved
Hide resolved
CodeEdit/Features/AppPreferences/Model/Text Editing/TextEditingPreferences.swift
Outdated
Show resolved
Hide resolved
CodeEdit/Features/AppPreferences/Model/Text Editing/TextEditingPreferences.swift
Outdated
Show resolved
Hide resolved
CodeEdit/Features/AppPreferences/Model/Text Editing/TextEditingPreferences.swift
Outdated
Show resolved
Hide resolved
...dit/Features/AppPreferences/Sections/TextEditingPreferences/TextEditingPreferencesView.swift
Outdated
Show resolved
Hide resolved
Also the Code does not currently compile. Please always clean-build the app before pushing the changes. |
…gPreferences.swift Co-authored-by: Lukas Pistrol <l.pistrol@gmail.com>
…gPreferences.swift Co-authored-by: Lukas Pistrol <l.pistrol@gmail.com>
…gPreferences.swift Co-authored-by: Lukas Pistrol <l.pistrol@gmail.com>
…gPreferences.swift Co-authored-by: Lukas Pistrol <l.pistrol@gmail.com>
…gPreferences.swift Co-authored-by: Lukas Pistrol <l.pistrol@gmail.com>
…gPreferences.swift Co-authored-by: Lukas Pistrol <l.pistrol@gmail.com>
@luah5 I just pushed a couple of my proposed changes which fixed some build errors and code duplication. It now looks like this and works as expected selection-wise: |
Could you please add some screenshots of how different encodings look like when rendered? Especially when using characters only available in a specific encoding. |
I'm pretty sure that ASCII would show something when decoding a UTF-32 string. Especially when most of the characters are also available in ASCII |
Marked as blocking since the UI part needs to be re-implemented once #1215 is merged. Also it does not work as expected yet (see this comment) |
Did I get it right that files which don't match the set encoding setting (in Settings pane) just open as a blank file? I would expect that displaying the file should at least be tried, rendering symbols not known in current encoding as for example question marks. With the current release some files with unknown encoding just open up as empty (see #1263). If this PR gets implemented displaying a file as empty should not happen IMHO. |
Closed due to too many merge conflicts. |
Description
This
PR
adds a preference for how files are to be encoded when read the options are:ascii
iso2022JP
isoLatin1
isoLatin2
japaneseEUC
macOSRoman
nextstep
nonLossyASCII
shiftJIS
symbol
unicode
utf16
utf16BigEndian
utf16LittleEndian
utf32
utf32BigEndian
utf32LittleEndian
utf8
Related Issues
Checklist
Screenshots
as you can see the file opens with UTF32 encoding but not in ascii