Jump to content

New SciTE4AutoIt3 available with SciTE v1.74


Jos
 Share

Recommended Posts

  • Developers

Two questions

Is there any chance to install SciTE4AutoIt3 to a computer with beta version of autoit3 only?

Sometimes, I prefer to download autoit3 without installer. However, SciTE4AutoIt3 refuses to install because of missing registry value of autoit3 version. Anyway to bypass?

Why is it people want to do things differently than a defined standard process ???? ;)

You could use the SciTE4AutoIt3.zip as well if you really want to do this in a different way.

:)

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

  • Replies 72
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Posted Images

  • Developers

Hi

JdeB, speaking about standard process: most of the time you find AutoIt and its subfolders, I guess looking at the Registry. But in some cases (at least when opening Includes from SciTE's Tools menu), you take the path from a properties file. For portability, it would be better if you "standardly" will always look for paths at the Registry, or at least allow relative path in the properties file. Would you think about this, please?

Are you talking about the Alt+I, ALt+Shift+I and Ctrl+J LUA functions?

If so, How would you retrieve values from the registry from LUA?

Have you tried to specify a relativepath for AutoIt3Dir in au3.properties and what was the problem with 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

JdeB:

I'm sorry I've made a big noise. I get an error I think was associated with the AutoIt path but, just checked, it (seems to be) doesn't have to do with the error.

No problem ... :)

The error: after I modified the relative path in au3.properties to ".\" (the parent folder), when I try Alt-I, the output windows states:

D:\-\Apps\SuperCD-II\AutoIt3\SciTE\AutoIt3.lua:958: attempt to use a closed file

>Lua: error occurred while processing command

But it doesn't happen always, sometimes the file opens OK. Besides, if after the error I close SciTE and relaunch it, the Include is open correctly.

This is with the previous release of SciTE, I'm not using the last SciTE yet.

alc

I am pretty sure this was reported and fixed in the latest release..

;)

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

9/9/2007: Uploaded a new SciTe4AutoIt3.exe installer.

==> ScitillaHistory page containing all SciTE/Scintilla updates.

==> Visit the SciTe4AutoIt3 Download page for the latest versions

==> Check the online documentation for an overview of all extras you get with this installer.

Enjoy,

Jos

9/9/2007
*** Updated AutoIt3Wrapper_Gui/AutoIt3Wrapper v1.9.3 (JdeB)
    - Added: %autoitdir% support in Run_Before and Run_After directives
    - Added: Skip the Source Directives update when no changes are made in AutoIt3Wrapper_GUI.
    - Added: #AutoIt3Wrapper_Res_SaveSource which will add the ScriptSource to the Output program resource section AutoIt3:ScriptSource.
    - Added: #AutoIt3Wrapper_Res_File_Add which will add the specified file to the Output program resource.
    - Removed: support for #AutoIt3Wrapper_allow_decompile and #AutoIt3Wrapper_passphrase 
    - Fixed: Possible issue with the Fileversion AutoIncrement replacing it on the wrong line.
    - Fixed: Bug running UPX in Win9x.
*** Updated Tidy.exe v2.0.17 (JdeB)
    - Added: rc = 99 in case any error condition occures and Tidy is abandoned.
    - Added: support for script line up to 4095 like AutoIt3.
    - Fixed: Make sure a space is added after a literal string when missing.
*** Updated Obfuscator.exe v1.0.20 (JdeB)
    - Fixed: crash when Include file contains record longer than 2047 characters.
    - Changed: String/Number encryption logic to make it harder to de-obfuscate.
    - Make "Include not found" error clearer and show up in the console output.
    - Fixed: hardcrash when the generated output record becomes longer than 2047 characters.
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

9/9/2007: Uploaded a new SciTe4AutoIt3.exe installer.

Thanks JDeB!

I will install it and update my resources UDF accordingly.

For now I noticed missing #AutoIt3Wrapper_Res_SaveSource directive in documentation (Scite4AutoIt3.chm and www.autoitscript.com/autoit3/scite/docs/AutoIt3Wrapper.htm)

Edited by Zedna
Link to comment
Share on other sites

  • Developers

Thanks JDeB!

I will install it and update my resources UDF accordingly.

For now I noticed missing #AutoIt3Wrapper_Res_SaveSource directive in documentation (Scite4AutoIt3.chm and www.autoitscript.com/autoit3/scite/docs/AutoIt3Wrapper.htm)

yes... missed that one, will be fixed in the next version of the helpfile.

It is documented in the Directives.au3 located in the AutoIt3Wrapper directory :)

Thanks

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 new AutoIt3Wrapper I noticed little cosmetic bug with UPX:

When compiling script in taskbar shows DOS box for UPX process, it's not hidden

$Pid = Run(@ComSpec & ' /c "' & $upxcmd & '"', "", -1, 2 + 4)

should be

$Pid = Run(@ComSpec & ' /c "' & $upxcmd & '"', "", @SW_HIDE, 2 + 4)
Edited by Zedna
Link to comment
Share on other sites

  • Developers

In new AutoIt3Wrapper I noticed little cosmetic bug with UPX:

When compiling script in taskbar shows DOS box for UPX process, it's not hidden

$Pid = Run(@ComSpec & ' /c "' & $upxcmd & '"', "", -1, 2 + 4)

should be

$Pid = Run(@ComSpec & ' /c "' & $upxcmd & '"', "", @SW_HIDE, 2 + 4)
Thanks.

You can add into next Scite4AutoIt3 version also new Koda 1.7

sure... :)

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

Why #AutoIt3Wrapper_Allow_Decompile=n is no longer getting special collors as all others #autoitwrapper functions? :)

... because the option in aut2exe is gone thus no use in supporting it anymore....

:)

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 updated my post with my resources UDF

and notticed bug in #AutoIt3Wrapper: When using #AutoIt3Wrapper_Res_File_Add on my WIN98SE it couldn't find reshacker.exe in #AutoIt3Wrapper directory due to empty path.

In AutoIt3Wrapper.ini I only set UseAnsi=1 and ResHackerPath= stay untouched/empty.

Global $ResHackerPath = IniRead(@ScriptDir & "\AutoIt3Wrapper.ini", "Config", "ResHackerPath", @ScriptDir)

$ResHackerPath variable was empty and reshacker.exe wasn't found (Scite output):

-*** ResHacker.exe program is missing in directory:

- To be able to update the resource information you need to download reshacker.exe from:

- http://angusj.com/resourcehacker/ and copy it to:

I filled AutoIt3Wrapper.ini like this to make workaround:

ResHackerPath=c:\Program Files\AutoIt3\SciTE\AutoIt3Wrapper

with this it works fine.

Link to comment
Share on other sites

  • 1 month later...

hello jos,

i have made a little change to AutoIt3Wrapper.au3 to make the window resizable (less scrolling, easier reading):

Func Show_Warnings($Warning_TiTle, $Warning_Text)
    GUICreate($Warning_TiTle, 700, 300, -1, -1, $WS_SIZEBOX+$WS_SYSMENU+$WS_MINIMIZEBOX)
    GUICtrlCreateLabel("Do you want to stop the " & $Option & "?", 5, 257, 180, 20)
    GUICtrlSetResizing(-1, $GUI_DOCKLEFT + $GUI_DOCKSIZE)
    Local $H_Yes = GUICtrlCreateButton("Stop", 280, 253, 60, 25)
    GUICtrlSetResizing($H_Yes, $GUI_DOCKBOTTOM + $GUI_DOCKSIZE + $GUI_DOCKHCENTER)
    Local $H_No = GUICtrlCreateButton("Continue anyway", 360, 253, 100, 25)
    GUICtrlSetResizing($H_No, $GUI_DOCKBOTTOM + $GUI_DOCKSIZE + $GUI_DOCKHCENTER)
    GUISetFont(9, 400, 0, "Courier New")
    GUICtrlCreateEdit(StringReplace($Warning_Text, @LF, @CRLF), 5, 5, 690, 240, BitOR($ES_WANTRETURN, $WS_VSCROLL, $WS_HSCROLL, $ES_AUTOVSCROLL, $ES_AUTOHSCROLL, $ES_READONLY))
    GUICtrlSetResizing(-1, $GUI_DOCKBORDERS)
    GUICtrlSetBkColor(-1, 0xFFEFEF)
    GUICtrlSetState($H_Yes, $GUI_FOCUS)
    GUISetState(@SW_SHOW)   ; Process GUI Input
    ; ...

but compiling does not work for me (i think because i have not rc.exe to include it).

do you like it?

AutoIt-Syntaxsheme for Proton & Phase5 * Firefox Addons by me (resizable Textarea 0.1d) (docked JS-Console 0.1.1)

Link to comment
Share on other sites

  • Developers

hello jos,

i have made a little change to AutoIt3Wrapper.au3 to make the window resizable (less scrolling, easier reading):

Func Show_Warnings($Warning_TiTle, $Warning_Text)
    GUICreate($Warning_TiTle, 700, 300, -1, -1, $WS_SIZEBOX+$WS_SYSMENU+$WS_MINIMIZEBOX)
    GUICtrlCreateLabel("Do you want to stop the " & $Option & "?", 5, 257, 180, 20)
    GUICtrlSetResizing(-1, $GUI_DOCKLEFT + $GUI_DOCKSIZE)
    Local $H_Yes = GUICtrlCreateButton("Stop", 280, 253, 60, 25)
    GUICtrlSetResizing($H_Yes, $GUI_DOCKBOTTOM + $GUI_DOCKSIZE + $GUI_DOCKHCENTER)
    Local $H_No = GUICtrlCreateButton("Continue anyway", 360, 253, 100, 25)
    GUICtrlSetResizing($H_No, $GUI_DOCKBOTTOM + $GUI_DOCKSIZE + $GUI_DOCKHCENTER)
    GUISetFont(9, 400, 0, "Courier New")
    GUICtrlCreateEdit(StringReplace($Warning_Text, @LF, @CRLF), 5, 5, 690, 240, BitOR($ES_WANTRETURN, $WS_VSCROLL, $WS_HSCROLL, $ES_AUTOVSCROLL, $ES_AUTOHSCROLL, $ES_READONLY))
    GUICtrlSetResizing(-1, $GUI_DOCKBORDERS)
    GUICtrlSetBkColor(-1, 0xFFEFEF)
    GUICtrlSetState($H_Yes, $GUI_FOCUS)
    GUISetState(@SW_SHOW)   ; Process GUI Input
    ; ...

but compiling does not work for me (i think because i have not rc.exe to include it).

do you like it?

Looks nice. I made a small change because the buttons were touching the border.

Have a look at this version to see if it works for you.

Thanks for your input <_<

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

yes, it does. :-)

remember size and position across restart will be nice too (just an idea).

i think about, to code a kind of releaseversion-codestripper.

it should strip all

marked (with special comments ";DEBUG",";DEBUG_START / ;DEBUG_END" or prefix in name "DEBUG_") debug-functions, debug-variables, etc.,

whitespace ("unintent"),

comments,

underscores in broken lines

and count all "talking" variables (long descriptive names) by usage, to replace them with short ones and this way reduce the size of compiled exe.

i have to do some other stuff first, but possibly somebody else does it right now :-)

AutoIt-Syntaxsheme for Proton & Phase5 * Firefox Addons by me (resizable Textarea 0.1d) (docked JS-Console 0.1.1)

Link to comment
Share on other sites

  • Developers

have you tried using this in your script:?

#AutoIt3Wrapper_Run_Obfuscator=y
#Obfuscator_Parameters=/cs 0 /cn 0 /cf 0 /cv 0 /sf 1

Try it and look at the Scriptname_Obfucated.au3 source. You will see that all white-space, comments and unneeded included UDFs are stripped.

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

Jos, here's something fun for you. I grew tired of the never-the-right-size horizontal scrollbar... so I wrote a Lua script to automatically calculate the correct width (more-or-less) based on the currently visible lines. That means as you move through the document, the scrollbar will automatically shrink (and disappear at times) or grow as needed. Really it's kind of slick. Naturally, it works best if you set this:

horizontal.scroll.width=0
output.horizontal.scroll.width=0
That way you start out with no scrollbar at all and my function will show it if it's actually necessary.

There are a few quirks. First, most of the time, when you scroll by using the mouse-wheel or vertical scrollbar, you have to do something to get the scrollbar to adjust. Clicking in the document is sufficient, and is probably what the user will be doing next anyway. Not a big deal, but for some reason the OnUpdateUI() event isn't fired when scrolling. As for the second quirk, it's related to the output pane. For whatever reason, it doesn't always work. For example, clearing the output pane doesn't clear the scrollbar, even though the event seems to be firing. So the output pane may be totally empty but still showing a horizontal scrollbar. Not sure how to fix that.

Surprisingly, for me at least, performance is not an issue. I would have thought this would be slow, particularly since it's being done via Lua on an event that fires quite a bit. But I can't tell any negative performance effects.

Here's the code:

-- Called when the UI is updated.
 function OnUpdateUI()
     CalculateHorizontalScrollWidth(editor)
     CalculateHorizontalScrollWidth(output)
     -- We want to allow others to play, too, so return false.
     return false
 end    -- OnUpdateUI()
 
 -- What we do here is calculate a new horizontal scroll width for the
 -- specified pane based on the longest line visible.
 -- args:
 --     pane - Specify either editor or output
 function CalculateHorizontalScrollWidth(pane)
     -- An interesting quirk, pane.FirstVisibleLine is 0-based but
     -- of course the display is 1-based.  Keep this in mind if
     -- debugging the line numbers and things look off-by-one.
     local longest_value = 0, longest_line, longest_temp
     local line
 
     -- Iterate over all the visible lines and find the longest.  Actually,
     -- we also iterate over the first non-visible line (at the bottom)
     -- as well just to prevent a loop where the scrollbar shows itself,
     -- obscures the line it's active for, then hides itself, then shows
     -- itself because the line becomes visible again, ad infinium.
     for line = pane.FirstVisibleLine, pane.FirstVisibleLine + pane.LinesOnScreen do
         -- Compute the longest line from the lines which are visible.
         longest_temp = pane:LineLength(line)
         if longest_temp > longest_value then
             longest_value = longest_temp
             longest_line = line
         end
     end
 
     -- If we have a really small longest_value, set the width to 0
     -- and return.  This doesn't seem to work correctly for the
     -- output pane.
     if longest_value <= 2 then
         pane.ScrollWidth = 0
         return
     end
 
     -- Get the start of the line, this is used to retrieve the entire line's text.
     local line_start = pane:PositionFromLine(longest_line)
     -- This variable stores the position of the first non-whitespace character.
     local line_pos = pane.LineIndentPosition[longest_line + 2]
     -- We want to use a non-whitespace style if we can.
     local style = pane.StyleAt[line_pos]
     -- We don't want to grab the newlines so use this confusing code
     -- to strip 1 or 2 characters off the length (Really just a ternary).
     local adjust = (pane.EOLMode == 0 and 2) or 1
     -- Retrieve the line's text so we can calculate the width.
     local line_data = pane:textrange(line_start, (line_start + longest_value) - adjust)
     -- TextWidth() doesn't handle tabs, so, we replace tabs with spaces set to the
     -- indent size.
     line_data = line_data:gsub("\t", string.rep(" ", pane.Indent))
     -- Get an estimated width of the line.  We iterate all styles and pick the longest.
     local width = 0, width_temp
     local i
     for i = 1, 32 do
         width_temp = pane:TextWidth(i, line_data)
         if width_temp > width then
             width = width_temp
         end
     end
 
     -- Set the new width.  Hopefully it will be enough.
     pane.ScrollWidth = width
 end    -- CalculateHorizontalScrollWidth()
Edited by Valik
Weird spacing in the first code tag.
Link to comment
Share on other sites

You know how Visual Studio shows pretty little icons next to things in it's auto-complete drop-downs which help you identify what the symbol is? Would anybody like their symbols in SciTE to show up in a similar manner...?

Link to comment
Share on other sites

  • Developers

Jos, here's something fun for you. I grew tired of the never-the-right-size horizontal scrollbar...

-snip-

I have grown used to hitting {END} to find the end of a line but will have a closer look at this for sure to include it into the standard package because agree its useful.

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

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