Jump to content

Scite4Autoit3 default encoding suggestion


Fenzik
 Share

Recommended Posts

Hello All!

i suggest to set default encoding in Scite4 for Autoit 3 to UTF 8 with Bom encoding, format recommended also in Autoit Help.

In last editor version, when i open new script, for example Czech characters (č, ř, ž) aren't correct.

So when i change Encoding to UTF 8 with Bom from Default Code page property state, everithing seems to be OK.

Thank you and sorry for potentialy duplicated content.

Fenzik

Link to comment
Share on other sites

  • Developers
2 hours ago, Fenzik said:

when i open new script, for example Czech characters (č, ř, ž) aren't correct.

You mean you open a new empty script and type these characters it is saved wrong, since the default is UTF8 without bom so would expect it to be that?

Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

When i open blank new script and type this characters, there are written as letters without typical language diacritics. So (č is showed as c), (ň is showed as n).

And characters are also saved like that.

And when i open new script, in File/Encoding submenu only item Code page property is checked, no any UTF 8 items.

When i check resp select one UTF 8 item from file/Encoding menu, everithing is OK, characters are shown correctly.

Link to comment
Share on other sites

  • Developers

So when you add this to your Scite Userconfig: (SciTE menu:Options/Open User properties file

NewFileEncoding=UTF8BOM

Things work correctly?

EDIT: and you are using the FULL version right, not the one supplied with the AUtoIt3 installer....right?

Jos

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

  • Developers
3 minutes ago, Fenzik said:

But it does'nt work when the new filename is passed to scite as argument.

I do not understand this statement:  What exactly do you do here?

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

I'm mainly using Total Commander with tool, which redirects configured extensions to proper editors.

So when i hyt F4 on .txt file, i't opens in Metapad.

When i hyt F4 on .au3, it opens in full version of Autoit Editor.

And Shift+f4 is making new blank file of specifyed type.

So when i hyt Shift+F4, type the filename with .au3 extension (for example: test.au3), the redirecting tool takes the name written by me and passes it to Autoit editor as argument.

An when i do this, above discussed characters are stil wrong.

 

But when i run Scite without arguments, after editing my properties as you wrote, everithink is OK.

Thank you again.

Link to comment
Share on other sites

  • Developers

Ok, understand now.

So please try adding this option as well in your SciTEUser.properties file:

utf8.auto.check=3

.. and see if that changes it.

Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

  • Developers

I see indeed that an empty file defaults to "code page properties" in stead of the set option. 
As soon as you put a few characters in there, it will default to the correct set default.

Will have a look to see if I can find that issue or if this needs to be reported on the official website.

Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

  • Developers

Could you try this version of SciTE and remove the above settings from your SciTEUSer.properties file to see if the default behaviour is correct now?

Thanks
Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

  • Developers

shoot ...  it was now working fine when opening an empty file, but you are right, when I type a command in CMD like "scite d:\temp\test3.au3" it still opens with a "code page" encoding...   going to check.

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

  • Developers

Update the Beta version with one that seems to be working also when opened with a file on the commandline.

Could you give that a try?

Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

In this case, it seems to me be the same as at the start of this topic.

I have no changes in config files.

And in both situations (empty documment / passed argument) is checked only Code page property.

It's not so big problem to switch it, it's only little detail, that would be nice to have automaticaly set.. :)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...