online converter for converting your autohotkey code into pretty indented source code.
free no registration needed.
do you like it? please leave feedback
http://sl5.it/SL5_preg_contentFinder/ex ... e_code.php
online converter: converts your autohotkey code into pretty indented source code.
online converter: converts your autohotkey code into pretty indented source code.
github>g_IntelliSense + next improvements + forum
ahk..org>onlineAHKprettyfy, ahk..com>Refactoring
ahk..com>newposts Unanswrd myposts, Donations are appreciated if I could help you
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
ahk..org>onlineAHKprettyfy, ahk..com>Refactoring
ahk..com>newposts Unanswrd myposts, Donations are appreciated if I could help you
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
Re: online converter: converts your autohotkey code into pretty indented source code.
Very nice, AutoHotkey prettify
Windows 10 x64 Professional, Intel i5-8500, NVIDIA GTX 1060 6GB, 2x16GB Kingston FURY Beast - DDR4 3200 MHz | [About Me] | [About the AHK Foundation] | [Courses on AutoHotkey]
[ASPDM - StdLib Distribution] | [Qonsole - Quake-like console emulator] | [LibCon - Autohotkey Console Library]
Re: online converter: converts your autohotkey code into pretty indented source code.
Thanks makes me happyjoedf wrote:Very nice, AutoHotkey prettify
BTW its Lite (online) Version of (offline) https://github.com/sl5net/SL5_AHK_Refac ... ce.php#L60
So if you want try this by yourself no prob
Last edited by SL5 on 14 Jul 2015, 20:33, edited 1 time in total.
github>g_IntelliSense + next improvements + forum
ahk..org>onlineAHKprettyfy, ahk..com>Refactoring
ahk..com>newposts Unanswrd myposts, Donations are appreciated if I could help you
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
ahk..org>onlineAHKprettyfy, ahk..com>Refactoring
ahk..com>newposts Unanswrd myposts, Donations are appreciated if I could help you
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
Re: online converter: converts your autohotkey code into pretty indented source code.
Oh cool haha, I'll try out this real soon
Windows 10 x64 Professional, Intel i5-8500, NVIDIA GTX 1060 6GB, 2x16GB Kingston FURY Beast - DDR4 3200 MHz | [About Me] | [About the AHK Foundation] | [Courses on AutoHotkey]
[ASPDM - StdLib Distribution] | [Qonsole - Quake-like console emulator] | [LibCon - Autohotkey Console Library]
Re: online converter: converts your autohotkey code into pretty indented source code.
Cool cool...
My suggestions:
- Add braces option (braces with control statement / braces on own line)
- Space / Tab intent (2, 3, 4 spaces or 1 tab)
- Space before conditional: if(x) / if (x)
Like the JavaScript beautifier I use
My suggestions:
- Add braces option (braces with control statement / braces on own line)
Code: Select all
while (x = y) {
something()
somethingelse()
}
Code: Select all
while (x = y)
{
something()
somethingelse()
}
- Space before conditional: if(x) / if (x)
Like the JavaScript beautifier I use
[AHK] v2.0.5 | [WIN] 11 Pro (Version 22H2) | [GitHub] Profile
Re: online converter: converts your autohotkey code into pretty indented source code.
.
Last edited by SL5 on 16 Jul 2015, 16:50, edited 1 time in total.
github>g_IntelliSense + next improvements + forum
ahk..org>onlineAHKprettyfy, ahk..com>Refactoring
ahk..com>newposts Unanswrd myposts, Donations are appreciated if I could help you
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
ahk..org>onlineAHKprettyfy, ahk..com>Refactoring
ahk..com>newposts Unanswrd myposts, Donations are appreciated if I could help you
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
Re: online converter: converts your autohotkey code into pretty indented source code.
have added two new Style. Two of the three seem to work pretty stablil. I have switched the style SL5net_small_v0.1 as standard for the offline version. next days i need care of another programming language. See you soon!
results:
http://sl5.it/SL5_preg_contentFinder/ex ... e_code.php
(hopefully also soon visible inside wikipedia: https://de.wikipedia.org/w/index.php?ti ... small-Stil )
In addition, you can now adjust indentation and switch between space and tab. In addition, your form data is stored on your computer with garlic.js, so you do not need make every new settings.
results:
http://sl5.it/SL5_preg_contentFinder/ex ... e_code.php
Code: Select all
; thats SL5net_small Version 0.1 Indent-Style
if(doIt)
{
if(doIt)
{
if ( next )
Check
else
Check = 5
if ( next )
{
Send,5b{Right 5}
}}}
Code: Select all
; thats SL5net_small+ NotRecommended Indent-Style
if(doIt){
if(doIt){
if ( next )Check
else
Check = 5
if ( next ){
Send,5b{Right 5}
}}}
Code: Select all
; thats free Indent-Style - like SL5net_small it dosent change the signature or body begin. your free to do it manually ;)
if(doIt)
{
if(doIt)
{
if ( next )
Check
else
Check = 5
if ( next )
{
Send,5b{Right 5}
}
}
}
github>g_IntelliSense + next improvements + forum
ahk..org>onlineAHKprettyfy, ahk..com>Refactoring
ahk..com>newposts Unanswrd myposts, Donations are appreciated if I could help you
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
ahk..org>onlineAHKprettyfy, ahk..com>Refactoring
ahk..com>newposts Unanswrd myposts, Donations are appreciated if I could help you
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
Re: online converter: converts your autohotkey code into pretty indented source code.
Hello,
Very nice tool SL5. I used it to indent the source code of my old script.exe. I extracted the flat/raw code source (not comment, no indentation) with Resource Hacker http://www.angusj.com/resourcehacker/. Just a comment about the result of this tool:
The line command (just) after this IF test is indented, so it's fine.
But the line (just) after this IF test is not indented, and it should be indented. I guess because the test contains parenthesis and/or quotes.
Is it possible to download this tool to use it offline? How?
Maybe you can fix this "bug". Thanks in advance and regards.
sam
Very nice tool SL5. I used it to indent the source code of my old script.exe. I extracted the flat/raw code source (not comment, no indentation) with Resource Hacker http://www.angusj.com/resourcehacker/. Just a comment about the result of this tool:
The line command (just) after this IF test is indented, so it's fine.
Code: Select all
If (0<Ct)
Code: Select all
If (0<InStr(LisO,Labl . "/"))
Maybe you can fix this "bug". Thanks in advance and regards.
sam
Last edited by samzz on 13 Nov 2016, 17:32, edited 1 time in total.
Re: online converter: converts your autohotkey code into pretty indented source code.
download it here: https://github.com/sl5net/SL5_preg_cont ... Source.phpsamzz wrote: ...
Is it possible to download this tool to use it offline? How?
Maybe you can fix this "bug". Thanks in advance and regards.
sam
of use eventually (slightly different) for e.g. use STRG + SHIFT + L
with https://github.com/sl5net/SL5_AHK_Refactor_engine
Last edited by SL5 on 21 Apr 2018, 21:57, edited 2 times in total.
github>g_IntelliSense + next improvements + forum
ahk..org>onlineAHKprettyfy, ahk..com>Refactoring
ahk..com>newposts Unanswrd myposts, Donations are appreciated if I could help you
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
ahk..org>onlineAHKprettyfy, ahk..com>Refactoring
ahk..com>newposts Unanswrd myposts, Donations are appreciated if I could help you
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
Re: online converter: converts your autohotkey code into pretty indented source code.
if you want to simulate this similar or slightly different. This is the abridged version of the core PHP source code. the main responsible part (from https://github.com/sl5net/SL5_preg_cont ... Source.php ).
Code: Select all
<?php
include_once("SL5_preg_contentFinder.php");
.....
$cf = new SL5_preg_contentFinder($file_content);
$cf->setBeginEnd_RegEx($old_open, $old_close);
$cf->setSearchMode('dontTouchThis');
$actual = $cf->getContent_user_func_recursive(
function ($cut, $deepCount, $callsCount, $posList0, $source1) use ($conf, $arguments, $new_open_default, $new_close_default, $charSpace, $newline, $indentSize, $getIndentStr) {
if ($cut['middle'] === false) return $cut;
$indentStr = $getIndentStr(1, $charSpace, $indentSize);
if (!isset($posList0['begin_end'])) $posList0['begin_end'] = strlen($source1);
$start = '' . substr($source1, $posList0['begin_begin'], $posList0['begin_end'] - $posList0['begin_begin']) . '';
$end = '' . ltrim(substr($source1, $posList0['end_begin'], $posList0['end_end'] - $posList0['end_begin'])) . '';
if ($conf['noNewlineAtEnd']) {
$doNoNewlineAtEnd = preg_match("/\W[}\s]*\}\R*$/ms", $cut['middle'], $m);
if ($doNoNewlineAtEnd)
$cut['middle'] = rtrim($cut['middle']) . '';
}
$cut['middle'] = implode($newline . '' . $indentStr, preg_split("/(\R)/m", $cut['middle']));
$cut['middle'] = '' . rtrim($start) . '' . $newline . '' .
$indentStr . '' . trim($cut['middle']) . '';
if ($conf['noNewlineAtEnd'] && $doNoNewlineAtEnd) {
$cut['middle'] .= $end . '' . $cut['behind'] . '';
} else {
$cut['middle'] .= $newline . '' . $end . '' . $cut['behind'] . '';
}
return $cut;
});
github>g_IntelliSense + next improvements + forum
ahk..org>onlineAHKprettyfy, ahk..com>Refactoring
ahk..com>newposts Unanswrd myposts, Donations are appreciated if I could help you
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
ahk..org>onlineAHKprettyfy, ahk..com>Refactoring
ahk..com>newposts Unanswrd myposts, Donations are appreciated if I could help you
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
-
- Posts: 15
- Joined: 27 Nov 2020, 04:31
Re: online converter: converts your autohotkey code into pretty indented source code.
SL5 wrote: ↑11 Jul 2015, 07:40online converter for converting your autohotkey code into pretty indented source code.
free no registration needed.
do you like it? please leave feedback
http://sl5.it/SL5_preg_contentFinder/examples/AutoHotKey/converts_your_autohotkey_code_into_pretty_indented_source_code.php
Some bugs when adjusting "{"
Last edited by BoBo on 31 Mar 2021, 16:35, edited 1 time in total.
Reason: Fixed broken link.
Reason: Fixed broken link.
Re: online converter: converts your autohotkey code into pretty indented source code.
What needs to happen to get this working inside VisualStudioCode?
I put a checkmark on "use Tab for indent?" but it still uses spaces.
I put a checkmark on "use Tab for indent?" but it still uses spaces.
Re: online converter: converts your autohotkey code into pretty indented source code.
@Chunjee
It looks like that's just the preview?
The "Pretty indented code" seems to have tab characters when enabled.
It looks like that's just the preview?
The "Pretty indented code" seems to have tab characters when enabled.
Windows 10 x64 Professional, Intel i5-8500, NVIDIA GTX 1060 6GB, 2x16GB Kingston FURY Beast - DDR4 3200 MHz | [About Me] | [About the AHK Foundation] | [Courses on AutoHotkey]
[ASPDM - StdLib Distribution] | [Qonsole - Quake-like console emulator] | [LibCon - Autohotkey Console Library]
- BrockPlaysFortnite
- Posts: 84
- Joined: 06 Nov 2021, 08:47
Re: online converter: converts your autohotkey code into pretty indented source code.
Seems buggy to me - I use the http://hilite.me/ one because this one always messes up my code. I am guessing it's one of those tools that used to work and doesn't anymore?
-
- Posts: 54
- Joined: 02 Jan 2018, 15:55
Re: online converter: converts your autohotkey code into pretty indented source code.
hilite.me converts code into . . HTML.
-
- Posts: 54
- Joined: 02 Jan 2018, 15:55
Re: online converter: converts your autohotkey code into pretty indented source code.
But I find that there is this web tool, called (perhaps) 'SL5', and which uses, er, a tool that seems written for another language. Except, er: I find also that the web tool mangles my Autohotkey code!
Re: online converter: converts your autohotkey code into pretty indented source code.
sort of - you're missing the point - if you look at the preview instead of the code it's formatted your line breaks and indentations
Re: online converter: converts your autohotkey code into pretty indented source code.
Greetings SL5,
First, thanks for writing AHK Prettyfy;
Second, how can I set the ELSE statements to be followed by curly brackets on their own line (Allman Indentation style)?
Like from:
to this:
First, thanks for writing AHK Prettyfy;
Second, how can I set the ELSE statements to be followed by curly brackets on their own line (Allman Indentation style)?
Like from:
Code: Select all
If (...)
{
;Statement
}else {
;Statement
}
Code: Select all
If (...)
{
;Statement
}
else
{
;Statement
}
Re: online converter: converts your autohotkey code into pretty indented source code.
VSCode Web and setting the formatter option one_true_brace to false.
For AHK2, you can do this by using Return to “Other Utilities & Resources”
Who is online
Users browsing this forum: No registered users and 8 guests