Jump to content

Scite and UDF support


Recommended Posts

Scite has autocomplete and infos support for the main includes (e.g. #include Array.au3).
https://www.bilder-upload.eu/bild-c2d9d2-1561640906.png.html
How do I achieve that for my UDFs?

Edited by diepfeile
Link to comment
Share on other sites

10 minutes ago, Earthshine said:

what is the problem? it's working for me. are you talking about adding your functions to the autocomplete?

Yes, It looks like it isn't triggered automatically with #include...

6 minutes ago, Subz said:

You will need to create your own udf and then use the following in the Full Scite

Tools > Scite Config > Run User Call Tip Manager

I already have my own UDFs, but they don't show up in the autocomplete nor do I get tips for their parameters, despite having them already #include'd.
https://www.bilder-upload.eu/bild-dd7b3b-1561642673.png.html
I found that though: https://www.autoitscript.com/forum/topic/70491-add-user-call-tips-to-scite-for-extra-udfs/

Link to comment
Share on other sites

The one I mentioned is the latest version of AutoIt, here are the full steps:

  • Click: Tools > Scite Config
  • Click: Other Tools Tab
  • Click: Run User CallTip Manager
  • Browse to your personal include folder
  • Select the UDF from the drop down list
  • If you have included headers for your functions select "Header Mode" otherwise select "Direct Mode" (Just uses the parameters)
  • Click: Parse button
  • Click: Add or Skip to add the call tips
  • Close and restart Scite

 

Link to comment
Share on other sites

Np, normally once I finish a personal udf, I would do the following:

  • Select: First line of the function i.e. Func Example(...)
  • Click: Tools > Make UDF Header
  • This will automatically create the header with the correct syntax and description of the parameters like below
  • Add a description
  • Go through the steps above using Header Mode
    The Call Tips Manager uses the Syntax and Description as the call tip.

Hope that helps.

; #FUNCTION# ====================================================================================================================
; Name ..........: Example
; Description ...: Function description
; Syntax ........: Example($_sRequired[, $iExample = 1])
; Parameters ....: $_sRequired          - an unknown value.
;                  $iExample            - [optional] an integer value. Default is 1.
; Return values .: None
; Author ........: Your Name
; Modified ......: 
; Remarks .......: 
; Related .......: 
; Link ..........: 
; Example .......: No
; ===============================================================================================================================
Func Example($_sRequired, $iExample = 1)

 

Link to comment
Share on other sites

  • Developers
23 minutes ago, Earthshine said:

thanks @Subz, that works, even my paramers show up. I did not even know you could do this, how nice.

Maybe something should be added here: https://www.autoitscript.com/wiki/Adding_UDFs_to_AutoIt_and_SciTE ? 
 

:) 

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
Just now, Earthshine said:

yes, even I need to read this stuff better! thank you. i love Scite as an editor

I've updated my post a little as there isn't much there about using the headers. 

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

43 minutes ago, Subz said:

The one I mentioned is the latest version of AutoIt, here are the full steps:

  • Click: Tools > Scite Config
  • Click: Other Tools Tab
  • Click: Run User CallTip Manager
  • Browse to your personal include folder
  • Select the UDF from the drop down list
  • If you have included headers for your functions select "Header Mode" otherwise select "Direct Mode" (Just uses the parameters)
  • Click: Parse button
  • Click: Add or Skip to add the call tips
  • Close and restart Scite

 

I should have the latest Beta Version: 3.3.15.0

"Click: Tools > Scite Config" This only works for me, if I have a saved file opened, doesn't work with a new one open. Thanks for the tip, I hoped that worked automatically though.

Link to comment
Share on other sites

  • Developers
2 minutes ago, diepfeile said:

I should have the latest Beta Version: 3.3.15.0

"Click: Tools > Scite Config" This only works for me, if I have a saved file opened, doesn't work with a new one open.

Guess you mean that SciTECOnfig is not available when you start a new file?
This is correct as you need to have a file open with .au3 as file extension to have the AutoIt3 extra tools available!

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

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