Jump to content

BETA: SciTE v5x & lua Dynamic_include and "Smart" AutoComplete for Vars/UDFs/Abbrevs


Recommended Posts

Posted

To be honest @Baraoic, I don't see the problem or at least it's not a big one.

In VS Code is the behavior the same, except the fact that the correct variable $aDirs is the first suggested item.

autoit-vscode-suggested-items.png

When you type more characters, the list will decrease and that's a common behavior like for other languages (and VSCode).
So in my personaly experience it's not distracted at all, but that's me of course.

Best regards
Sven

==> AutoIt related: 🔗 Organization AutoIt Community🔗 GitHub, 🔗 Discord Server, 🔗 Cheat Sheet🔗 autoit-webdriver-boilerplate

Spoiler

🌍 Au3Forums

🎲 AutoIt (en) Cheat Sheet

📊 AutoIt limits/defaults

💎 Code Katas: [...] (comming soon)

🎭 Collection of GitHub users with AutoIt projects

🐞 False-Positives

🔮 Me on GitHub

💬 Opinion about new forum sub category

📑 UDF wiki list

✂ VSCode-AutoItSnippets

📑 WebDriver FAQs

👨‍🏫 WebDriver Tutorial (coming soon)

Posted
Posted (edited)

Thanks @Nine. Understandable, yes. Also more preferable, I agree.
In my case it doesn't matter, because I use VSCode and GitHub Copilot which takes over the suggestion and autocompletion part entirly.
Means the correct context (block) based variable is autocompleted and I don't see such problems.

For the test and for the screenshot (I made), I turned GitHub Copilot off, to simulate the behavior without my setup.

Anyhow, thanks for the clarification, the old version is more preferable, yes (at least for SciTE).

Best regards
Sven

Edited by SOLVE-SMART

==> AutoIt related: 🔗 Organization AutoIt Community🔗 GitHub, 🔗 Discord Server, 🔗 Cheat Sheet🔗 autoit-webdriver-boilerplate

Spoiler

🌍 Au3Forums

🎲 AutoIt (en) Cheat Sheet

📊 AutoIt limits/defaults

💎 Code Katas: [...] (comming soon)

🎭 Collection of GitHub users with AutoIt projects

🐞 False-Positives

🔮 Me on GitHub

💬 Opinion about new forum sub category

📑 UDF wiki list

✂ VSCode-AutoItSnippets

📑 WebDriver FAQs

👨‍🏫 WebDriver Tutorial (coming soon)

  • Developers
Posted (edited)

Nice that a new feature, which now also considers the included files  and standard includes with AutoComplete, is considered an issue. 
Simply disable the new feature in your setup, and all will be as it was before... nice and limited. 😉

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.
  :)

  • Developers
Posted (edited)
3 hours ago, argumentum said:

..since we're talking about it, the reason I don't use SciTE v5 is the autocomplete. If that could be changed in a LUA file ( or somewhere ) to behave like in v4, I'd give it a go.

2 things:

1. SciTE is totally unrelated to the new lua scripts in the Scite4autoit3 package.

2. If you would take the time to read or even ask, you would quickly find out that it is configurable in the new setup.

I honestly fail to see why it isn't useful but won't shed any tears and have decided I won't be doing any new development on the lua-scite stuff as its clear their is hardly anybody that care except for a few regulars.

 

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.
  :)

Posted
29 minutes ago, Jos said:

2 things:

1. SciTE is totally unrelated to the new lua scripts in the Scite4autoit3 package.

2. If you would take the time to read or even ask, you would quickly find out that it is configurable in the new setup.

Am a bit out of touch with v5. I want to install 3.3.18.0 with the SciTE v5 ( in another PC ), given that all my setups are still with 3.3.16.1.

What do I run to install the v5 ? Run the SciTE4AutoIt3_vsc.exe and update with the SciTEx64.zip ?

Follow the link to my code contribution ( and other things too ).
FAQ - Please Read Before Posting.
autoit_scripter_blue_userbar.png

Posted
2 hours ago, Jos said:

I honestly fail to see why it isn't useful but won't shed any tears and have decided I won't be doing any new development on the lua-scite stuff as its clear their is hardly anybody that care except for a few regulars.

Understandable from my point of view @Jos.

I though you already wanted to focus more on "VSCode first" development as we (some of us) discussed this in thread Visual Studio Code Extension currently available and future plans for SciTE?. Maybe I misunderstood your statement in the different posts (of the thread), but anyway, thanks for the effort 🤝 .

Best regards
Sven

==> AutoIt related: 🔗 Organization AutoIt Community🔗 GitHub, 🔗 Discord Server, 🔗 Cheat Sheet🔗 autoit-webdriver-boilerplate

Spoiler

🌍 Au3Forums

🎲 AutoIt (en) Cheat Sheet

📊 AutoIt limits/defaults

💎 Code Katas: [...] (comming soon)

🎭 Collection of GitHub users with AutoIt projects

🐞 False-Positives

🔮 Me on GitHub

💬 Opinion about new forum sub category

📑 UDF wiki list

✂ VSCode-AutoItSnippets

📑 WebDriver FAQs

👨‍🏫 WebDriver Tutorial (coming soon)

Posted
16 minutes ago, Nine said:

Use my searchcontent tool in scite folder.  You should find it in no time.

oh !, but I do use your script. Is the best there is. Just awesome.
The problem is in that while coding I press "$i" and the list from every include makes it cumbersome to select those in the script, hence my request.

Follow the link to my code contribution ( and other things too ).
FAQ - Please Read Before Posting.
autoit_scripter_blue_userbar.png

Posted
7 hours ago, Jos said:

2 things:

1. SciTE is totally unrelated to the new lua scripts in the Scite4autoit3 package.

2. If you would take the time to read or even ask, you would quickly find out that it is configurable in the new setup.

I honestly fail to see why it isn't useful but won't shed any tears and have decided I won't be doing any new development on the lua-scite stuff as its clear their is hardly anybody that care except for a few regulars.

 

I do appreciate your work and I'm sure some people enjoy the recursive autocomplete, but I personally don't.

I use vscode for powershell and while it does add some extra random ones, it only adds a handful at worse, not nearly as many.

I'm asking how to change it because I couldn't figure out how? The install process didn't appear to have that option as far as I can tell. I did open SciTEGlobal.properties and skim through there and even tried changing a few, but that didn't help. So I figured I'd just ask instead of randomly changing properties.


 

2 hours ago, Nine said:

Use my searchcontent tool in scite folder.  You should find it in no time. :)

I asked the question because I couldn't figure out what property to change... If you know the property name then please do share.

Posted
2 hours ago, Nine said:

I mean search for autocomplete in all files in scite folder. You will find it.

setting dynamic.include=n in au3.properties does set it back to the old style, but it also breaks the new auto include, which was really nice and I'd like to keep.

I already messed with the autocomplete options in that file before my initial post and they don't help.

It looks like AutoItAutoComplete.lua controls both the include logic and autocomplete logic, but trying to just revert only the autocomplete is more complicated than it appears. I do see it has a Old_AutoComplete function it uses on unsaved files, but that also doesn't allow the new auto include so I'd have to change the main autocomplete function while not breaking the auto include. Will have to look into it more tomorrow.

Posted (edited)
9 hours ago, argumentum said:

How can I declare to only include the variables is the current script ?

27 minutes ago, Baraoic said:

dynamic.include=n in au3.properties does set it back to the old style, but it also breaks the new auto include, which was really nice and I'd like to keep.

Ok that did solve the long list of unrelated variables but also took away other new interesting features.

Any way to separate the type of autocomplete ?, variables vs. functions ? .... but I'd like to keep the variables of the includes that are not UDFs ...so, a way to exclude via an exclude list of variables to not present as part of the list of variables 😅

Goodness, am a pain. I should have asked these questions a year ago when you were actively working on it.

Edit: @Jos please put the baseball bat down and don't hit me. It is as it is, and if I participated earlier ... it wouldn't be so frustrating for you dealing with these questions so late in the game.

Edited by argumentum
feel bad about my questions

Follow the link to my code contribution ( and other things too ).
FAQ - Please Read Before Posting.
autoit_scripter_blue_userbar.png

  • Developers
Posted (edited)
On 1/7/2026 at 4:38 AM, Baraoic said:

Thank you for the update. I love the auto Include and it works great, but is it possible to set auto complete back to the old way? I hate the auto complete being filled with completely irrelevant options as in the screenshot.

 

Ok, so tell me which part in your mind is irrelevant in your example in general and do you not see the Variable you are looking for at the top when you type the proper starting characters? Ok, its maybe not at the first place in the list, but it should be close to the top.
One of the nice things about the new version is that it also matches the typed characters after the $ inside the options, which means you do not have to remember the exact starting characters anymore. 

In case you are looking for the standard SciTE behaviour, you could type Ctrl+Enter when the full list is shown and it will switch to the old list.

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.
  :)

Posted
3 hours ago, Jos said:

To make the AutoCompletelist configurable as to what is shown you could make a few simple changes:

to your user.properties add lines:

# Use only current file for autocomplete options / old behaviour
autocomplete.au3.currentonly=y

Change if on line 298 in AutoItAutoComplete.lua to:

   -- check if Dynamic is used and the Filename <> "" (Happens when the file isn't saved yet)
   -- also check for autocomplete.au3.currentonly=y to force old behaviour
   if not AutoItDynamicIncludes:Dynamic_includes() or props['FileNameExt'] == '' or props['autocomplete.au3.currentonly']:match('[1yY]') then
      -- Use Old behaviour
      AutoItAutoComplete:Old_AutoComplete(c)
      return false
   end

... but I still want to list all possible variables for GUI, WIN..etc UDFs plus all possible functions in the project, as I can never remember their exact spelling. 😉 

Perfect, that's exactly what I wanted. Thank you.

Posted (edited)

@Jos I've been noticing issue with CTRL + J for a long time, today I noticed the cause.

Description:
Using CTRL+J multiple times for the same function always opens a new document window, instead of switching to the window that was already open.

STEP BY STEP PROCEDURE:

  1. open FileWrite.au3 example
  2. move cursor to _WinAPI_GetTempFileName()
  3. use CTRL + J
  4. switch back to FileWrite.au3
  5. use CTRL + J on focused  _WinAPI_GetTempFileName()
  6. it open a new window instance in SciTE editor instead using that one which was opened after first CTRL + J usage.

 

Edited by mLipok

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

Spoiler

Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind. 

My contribution (my own projects): * Debenu Quick PDF Library - UDF * Debenu PDF Viewer SDK - UDF * Acrobat Reader - ActiveX Viewer * UDF for PDFCreator v1.x.x * XZip - UDF * AppCompatFlags UDF * CrowdinAPI UDF * _WinMergeCompare2Files() * _JavaExceptionAdd() * _IsBeta() * Writing DPI Awareness App - workaround * _AutoIt_RequiredVersion() * Chilkatsoft.au3 UDF * TeamViewer.au3 UDF * JavaManagement UDF * VIES over SOAP * WinSCP UDF * GHAPI UDF - modest begining - comunication with GitHub REST APIErrorLog.au3 UDF - A logging Library * Include Dependency Tree (Tool for analyzing script relations) * Show_Macro_Values.au3 *

 

My contribution to others projects or UDF based on  others projects: * _sql.au3 UDF  * POP3.au3 UDF *  RTF Printer - UDF * XML.au3 UDF * ADO.au3 UDF SMTP Mailer UDF * Dual Monitor resolution detection * * 2GUI on Dual Monitor System * _SciLexer.au3 UDF * SciTE - Lexer for console pane

Useful links: * Forum Rules * Forum etiquette *  Forum Information and FAQs * How to post code on the forum * AutoIt Online Documentation * AutoIt Online Beta Documentation * SciTE4AutoIt3 getting started * Convert text blocks to AutoIt code * Games made in Autoit * Programming related sites * Polish AutoIt Tutorial * DllCall Code Generator * 

Wiki: Expand your knowledge - AutoIt Wiki * Collection of User Defined Functions * How to use HelpFile * Good coding practices in AutoIt * 

OpenOffice/LibreOffice/XLS Related: WriterDemo.au3 * XLS/MDB from scratch with ADOX

IE Related:  * How to use IE.au3  UDF with  AutoIt v3.3.14.x * Why isn't Autoit able to click a Javascript Dialog? * Clicking javascript button with no ID * IE document >> save as MHT file * IETab Switcher (by LarsJ ) * HTML Entities * _IEquerySelectorAll() (by uncommon) * IE in TaskSchedulerIE Embedded Control Versioning (use IE9+ and HTML5 in a GUI) * PDF Related:How to get reference to PDF object embeded in IE * IE on Windows 11

I encourage you to read: * Global Vars * Best Coding Practices * Please explain code used in Help file for several File functions * OOP-like approach in AutoIt * UDF-Spec Questions *  EXAMPLE: How To Catch ConsoleWrite() output to a file or to CMD *

I also encourage you to check awesome @trancexx code:  * Create COM objects from modules without any demand on user to register anything. * Another COM object registering stuffOnHungApp handlerAvoid "AutoIt Error" message box in unknown errors  * HTML editor

winhttp.au3 related : * https://www.autoitscript.com/forum/topic/206771-winhttpau3-download-problem-youre-speaking-plain-http-to-an-ssl-enabled-server-port/

"Homo sum; humani nil a me alienum puto" - Publius Terentius Afer
"Program are meant to be read by humans and only incidentally for computers and execute" - Donald Knuth, "The Art of Computer Programming"
:naughty:  :ranting:, be  :) and       \\//_.

Anticipating Errors :  "Any program that accepts data from a user must include code to validate that data before sending it to the data store. You cannot rely on the data store, ...., or even your programming language to notify you of problems. You must check every byte entered by your users, making sure that data is the correct type for its field and that required fields are not empty."

Signature last update: 2023-04-24

  • Developers
Posted
9 hours ago, mLipok said:

Using CTRL+J multiple times for the same function always opens a new document window, instead of switching to the window that was already open.

This seems to have been a bug in the SciTE 5.5.6 version as the 5.5.8 doesn't show this behavior anymore. Its now available in Beta SciTEx86.zip & SciTEx64.zip files.

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.
  :)

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
×
×
  • Create New...