Jump to content

Adding file association extensions to SciTe


golfjrr
 Share

Recommended Posts

I decided to give SciTE a try and it is interesting to say the least. The question I have is how do I get it associated with file extensions other than .au3.

All my include extenstions are .ai3 so I can differentiate them from the actual main programs. How do I add .ai3 files so the are treated the same as .au3 files by SciTe?

Link to comment
Share on other sites

  • Developers

I decided to give SciTE a try and it is interesting to say the least.  The question I have is how do I get it associated with file extensions other than .au3. 

All my include extenstions are .ai3 so I can differentiate them from the actual main programs.  How do I add .ai3 files so the are treated the same as .au3 files by SciTe?

<{POST_SNAPBACK}>

Open your SciteUser.properties via Options/User options file and add this line to it:

file.patterns.au3=*.au3;*.ai3

Edited by JdeB

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

Open your SciteUser.properties via Options/User options file and add this line to it:

file.patterns.au3=*.au3;*.ai3

<{POST_SNAPBACK}>

Does it matter where I add it? I see warnings in the file.. Don't change anything after this line and at the bottom, don't change anything before this line? Kind of telling me not to mess with it.

I don't want to mess anything up as I don't understand how that file is processed.

Link to comment
Share on other sites

  • Developers

Does it matter where I add it? I see warnings in the file.. Don't change anything after this line and at the bottom, don't  change anything before this line? Kind of telling me not to mess with it.

I don't want to mess anything up as I don't understand how that file is processed.

<{POST_SNAPBACK}>

anywhere except between the lines with the warnings...

Best thing is to put your own modifications at the top of the file.

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

Warnings. That would be the SciteConfig entries. Do not change anything between the marked lines. You can add information above or below the Scite Config entries.

Easier, to above.

Any entries inserted into this file, overrules au3 options and global options. If you want to make changes, it would be in the user options file.

:lmao:

Link to comment
Share on other sites

  • Developers

Have a look here

:lmao:

<{POST_SNAPBACK}>

@golfjrr, This is a modification to open the file by default with SciTE which you also may want to do !!

The changes i gave is to have SciTE use the same Lexer as for au3 (syntax highlighting and folding) o:)

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

Warnings. That would be the SciteConfig entries. Do not change anything between the marked lines. You can add information above or below the Scite Config entries.

Easier, to above.

Any entries inserted into this file, overrules au3 options and global options. If you want to make changes, it would be in the user options file.

:lmao:

<{POST_SNAPBACK}>

Besides, the USER or LOCAL options don't get overwritten when you do a re-install of SciTE when there's a handy update from jdbe.

Lofting the cyberwinds on teknoleather wings, I am...The Blue Drache

Link to comment
Share on other sites

Local Options are saved in the current working script directory. So they will not become lost. If you have 2000/XP, your user options are saved in your profile directory (Documents and Settings). Global options are in the Scite directory, but you do not enter information in it anyway.

:lmao:

Link to comment
Share on other sites

Besides, the USER or LOCAL options don't get overwritten when you do a re-install of SciTE when there's a handy update from jdbe.

<{POST_SNAPBACK}>

I inserted this line at the bottom of SciTEUser.properties via the method Options/Open user options file.

file.patterns.au3=*.au3;*.ai3

Of course the .ai3 files are not associated as far as opening automatically etc, but that's the next step. When I go to the open menu and open one manually it still doesn't show any of the syntax highlighting etc. leading me to believe this didn't work.

I looked at the fileassociations.au3 script and it is adding registry entries. It obviously doesn't have anything for .ai3 files and I don't know what the $KEY would be.

Am I the only one that does this with include files? Does everybody just call them all *.au3? (I find that real confusing). In any other language I have always seen/used different extenstions on modules/includes vs main programs.

In textpad this was easy to change just by going into preferences/document class/autoit and adding the additional extensions. I was hoping for something as easy here. I can definitely see great advantages to SciTe over Textpad but sometimes it seems in the advancement, you lose the ease of doing simple things.

Link to comment
Share on other sites

  • Developers

I inserted this line at the bottom of SciTEUser.properties via the method  Options/Open user options file. 

file.patterns.au3=*.au3;*.ai3

Of course the .ai3 files are not associated as far as opening automatically etc, but that's the next step. When I go to the open menu and open one manually it still doesn't show any of the syntax highlighting etc.  leading me to believe this didn't work.

<{POST_SNAPBACK}>

dunno why but this does work:

file.patterns.au3=*.au3;*.ai3

lexer.$(file.patterns.au3)=au3

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

dunno why but this does work:

file.patterns.au3=*.au3;*.ai3

lexer.$(file.patterns.au3)=au3

<{POST_SNAPBACK}>

Well it sort of works. It appears some of the text is colored (like numbers, strings, etc, and I see the indentation guides in the .ai3 files, but as an example none of the reserved words/keywords are colored so something isn't getting picked up.
Link to comment
Share on other sites

  • Developers

Well it sort of works. It appears some of the text is colored (like numbers, strings,  etc, and I see the indentation guides in the .ai3 files, but as an example none of the reserved words/keywords are colored so something isn't getting picked up.

<{POST_SNAPBACK}>

yea there is something strange here... :lmao:

When you make the change to au3.properties, things seems to work file ......

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

So is there a relatively simple workaround or is it hosed?

<{POST_SNAPBACK}>

for the time being just update au3.properties.... you will only have to remember to change it again after you do an update of SciTE4AutoIT3....

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

for the time being just update au3.properties....  you will only have to remember to change it again after you do an update of SciTE4AutoIT3....

<{POST_SNAPBACK}>

Thanks for the reply. All is well now (at least until I do an update and forget (hehe))...
Link to comment
Share on other sites

Thanks for the reply. All is well now (at least until I do an update and forget (hehe))...

<{POST_SNAPBACK}>

I found another little annoyance. How do I make it so I can do the functions like Tidy, syntax check and such on these .ai3 files. I don't get the nice list of tools with the .ai3 extension files that I get with .au3 files. Also when you do the file opens, it would be nice to be able to filter both ai3 and au3 files in the list.
Link to comment
Share on other sites

  • Developers

I found another little annoyance. How do I make it so I can do the functions like Tidy, syntax check and such on these .ai3 files. I don't get the nice list of tools with the .ai3 extension files that I get with .au3 files.  Also when you do the file opens, it would be nice to be able to filter both ai3 and au3 files in the list.

<{POST_SNAPBACK}>

What about just using *.au3 for everything or is that too simple ??? o:)

This version of http://www.autoitscript.com/fileman/users/jdeb/test/au3.properties will work for you..... :lmao:

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

What about just using *.au3 for everything or is that too simple ???    o:)

This version of http://www.autoitscript.com/fileman/users/jdeb/test/au3.properties will work for you..... :lmao:

<{POST_SNAPBACK}>

Nah, too simple. :)

I understand why he's doing it and I'd do the same myself but am content with leaving well enough alone.

Lofting the cyberwinds on teknoleather wings, I am...The Blue Drache

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

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...