This App is No Longer Maintained. Visit the Replacement at StrokesPlus.net

StrokesPlus Forum
                       
StrokesPlus Forum
Home | Profile | Active Topics
Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 General Discussion
 General Discussion
 Okay, fine...
 Forum Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

Rob

USA
2615 Posts

Posted - 05/19/2013 :  15:07:07  Show Profile  Visit Rob's Homepage
I think I've decided I will rewrite S+ instead of walking away and open sourcing it.

Think being the operative word Time will tell, but I feel that I might like to at least give it one more big overhaul, if nothing else.

However, this means there will be BIG changes. To begin with, I would rewrite the entire application (still in native C++, of course) from the ground up. I will try my best to separate the Windows-specific code in such a way that later someone (else!) could theoretically fork S+ to other platforms (Linux, Mac).

Additionally, the user interface will be written in HTML5 instead of Win32. This will make it far easier to enable a modern, user-friendly UI which can be easily enhanced, updated, or even changed by the user themselves.

Of course, the main reason why an HTML5 UI would be possible is because (here it comes...), Lua would be completely non-existent. Yep, you'd have to recreate all of your scripts. There are a few major reasons for this.

1. JavaScript is ubiquitous. It has only gained traction in recent years and has absolutely zero danger of going away. But also, more and more people are familiar with, and being taught, JS.

2. The V8 engine is very powerful. For those unfamiliar, V8 is the JavaScript engine that Google built, which is embedded into Chrome and was the first to obliterate every other JS engine in existence at the time, by an order of magnitude. Neither Google nor V8 are in danger of going away or having a lack of resources being thrown at the engine and it's future growth. The V8 engine can be embedded into a C++ application, exposing C++ functions, etc. to JavaScript and vice versa. So many simple action scripts would look very similar, for example, acSendKeys("test") would not be any different at all. However, if then blocks, variable declaration, etc. would have to be ported to Javacript from Lua. All in all, I don't see this as being a huge issue as most folks with very elaborate scripts would have no problem porting the logic.

3. JavaScript explicitly supports Unicode. One the major failings of S+ has been the lack of Unicode support, specifically when it comes to international users. That is simply unacceptable to me. Yes, there are some libraries/ways to enable Unicode support within Lua, but nothing I've found competes with the inherent support built into JavaScript. The new version of S+ would be 100% Unicode compatible, enabling users of all languages to have the same functionality as current English users do.

This time, there will be boat loads of exception handling, logging ability, etc. Plus, the V8 engine has a powerful context structure which will allow for multiple action sequences to run concurrently (S+ only has 2 Lua states, and the collisions of firing actions in those states and which one is running a script is the cause of many crashes).

Additionally, it will be much easier to create action wizards and other features which will make it less intimidating for folks who are not familiar with scripting.

There are still a few things I'll need to iron out regarding the UI and making sure it is a real possibility, but I think it should be perfectly doable.

Now, I'm not going to throw myself at this rewrite with the same voracity I did the first time I set out to create S+. I'm going to be taking my sweet time, chipping away a little bit here and there. The goal being to make it right the first time, and something that I can feel proud of, as well as have a code base which could be released which is not a hack-job of a program slapped together by a rookie C++ programmer

It will be a while until there's anything to see, but feel free to post your thoughts and ideas in this thread. I want to make sure that I build it with a much more flexible architecture this time.

Andreasvb

Sweden
46 Posts

Posted - 05/19/2013 :  20:30:54  Show Profile
Cool!

Would it still be limited with not activating the window when performing the gestures?
I don't really need it to activate, more like it should affect the window I have under the cursor and not the active window, like it is now.
That's the main reason I can't use it fully, you wouldn't want to close the wrong window.

Also, I'll be happy to try it if you want and to help finding bugs and come with suggestions.

Great to see it will live on.

Windows 8.1u3 Pro x64 Media Center / Portable StrokesPlus 2.8.2.0

Edited by - Andreasvb on 05/19/2013 20:31:54
Go to Top of Page

Noesis

25 Posts

Posted - 05/20/2013 :  10:27:03  Show Profile
Andreasvb,
S+ does already do what you want, but you need to change the close action so it uses the S+ function "acCloseApplication(nil, gsx, gsy)", which is also what you get if you select the function in the drop down list and click on insert. The default action S+ comes with, ie using acSendKeys to send the ALT+F4 key combo does do as you describe, but my thoughts are that is good and should be kept the same, as using send keys for some things means you don't have to be over the app you want to control to do it, or you can code to send the keys to window(s) of your choice not just the active window since you can activate the desired window before sending the keys then change it back after the keys are sent if you want ie sending keys should maintain the current functionality in my opinion, and as Rob suggested in his post.

Rob,
Glad to hear you are sticking with S+ !!, even if it's only "thinking" at this stage.
Go to Top of Page

Andreasvb

Sweden
46 Posts

Posted - 05/20/2013 :  12:18:17  Show Profile
It won't activate the window, I've tried many different ways.
Closing was just an example of all actions I use.

I use this in Global Lua:

acActivateWindowUnderMouseWheel(1)
function sp_before_action(gnm, gsx, gsy, gex, gey, gwd, gapp, gact)
acActivateWindow(nil, gsx, gsy,0)
end

It's something in Windows that blocks it, a limit in Lua or something.
You can read the thread about it here: http://www.strokesplus.com/forum/topic/314/actions-occur-to-focused-window

Hopefully a rewrite in HTML5/JS might bring that feature to life.


I like to multitask, so typing in one program and browsing in another at the same time but without losing focus to the first one.
I've written an AHK script to scroll under the cursor for that.

Then I want to fire an action to the window under my cursor but it affects the active instead.

I've lost count how many times mIRC has switched channel when trying to close an Explorer window.

Windows 8.1u3 Pro x64 Media Center / Portable StrokesPlus 2.8.2.0
Go to Top of Page

Noesis

25 Posts

Posted - 05/21/2013 :  12:38:05  Show Profile
Sorry I can't be of much help as the issue doesn't happen on my end.

I have however had a similar issue in a different set of programs & the solution there was to put in a small delay i.e. activate new window, delay, send keys, delay, activate the original window. Only mention it as it seems as though the keys are being sent before the window is actually activated.

Might seem stupid as the script says to activate window then send the keys but what might be happening (as an example) is Windows sees activate the window under the mouse coordinates and sends that to the graphics card/handler to do, ticks it off it's todo list and sends the keys, in the mean time the window may not have actually been activated as the graphics card/handler was busy for a millisecond or two (and this is assuming windows isn't blocking the change due to S+ not having the permission to do so as discussed in the other thread).

Anyway just a thought, and I hope this rewrite does fix it for you now I know you didn't mean changing the functionality of the actual send keys function :)
Go to Top of Page

breakcore

Russia
74 Posts

Posted - 05/23/2013 :  15:34:17  Show Profile
Even if rewriting will take 2-3 years I'm very happy it will become more flexible.
For me JS is very convenient. But at the same time It's a little sad to leave LUA as I've come to like it.
I'll try to offer my help from time to time.
Wow, this is great news!
Go to Top of Page

plunt

Italy
88 Posts

Posted - 05/23/2013 :  15:46:57  Show Profile
There is a risk that V8 is more heavy and resource-hungry that LUA?
Go to Top of Page

Rob

USA
2615 Posts

Posted - 05/23/2013 :  15:51:54  Show Profile  Visit Rob's Homepage
No idea yet. These thoughts are very preliminary, one of the first things I'll do is build a simple project with V8 and see what it really looks like in terms of resources. In theory, it doesn't *seem* like there should be a dramatic difference using a very simple engine. I haven't looked at the V8 source at all yet, there may be defs which can strip out parts I wouldn't need, etc.

We'll see, if it is noticeably heavier, then I'd re-evaluate things.
Go to Top of Page

rafal.enden

3 Posts

Posted - 06/02/2013 :  11:01:30  Show Profile
Did you consider using JAVA language for gesture app?
It would work on any platform with installed JAVA engine.
Go to Top of Page

Andreasvb

Sweden
46 Posts

Posted - 06/02/2013 :  17:29:12  Show Profile
quote:
Originally posted by rafal.enden

Did you consider using JAVA language for gesture app?
It would work on any platform with installed JAVA engine.

I don't want to touch anything Java, thank you. The JRE isn't the most secure, many exploits lately.

Windows 8.1u3 Pro x64 Media Center / Portable StrokesPlus 2.8.2.0
Go to Top of Page
  Previous Topic Topic Next Topic  
 Forum Locked
 Printer Friendly
Jump To:
StrokesPlus Forum © 2011-2018 Rob Yapchanyk Go To Top Of Page
Snitz Forums 2000