AutoHotkey Community

It is currently May 26th, 2012, 11:38 pm

All times are UTC [ DST ]




Post new topic This topic is locked, you cannot edit posts or make further replies.  [ 87 posts ]  Go to page Previous  1, 2, 3, 4, 5, 6  Next
Author Message
 Post subject: Thanks
PostPosted: October 25th, 2009, 4:45 pm 
Offline

Joined: March 12th, 2007, 5:25 am
Posts: 14
Titan wrote:
Sure. To understand what progress we are making I need to give an overview of the design.

Awesome, thanks for the update and for the overview of the project! I'm looking forward to the Beta - and let us know if you could use help on anything.

_________________
-Thracx

"Man wants to know, and when he ceases to do so, he is no longer a man."
-Fridtjof Nansen


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 4th, 2009, 5:15 am 
Offline

Joined: February 17th, 2008, 5:01 pm
Posts: 303
I'm also really looking forward to the beta. What I'm most excited about is the potential that this might have for interaction between different languages. For example, I'm considering learning C#, and it sounds like I would be able to use Rusty to call the built-in AHK functions that I'm already comfortable with from my C# code. Am I right in this? Would the syntax be cumbersome? I really like the idea of turning AHK into a library that can be called from any .net language.

Likewise, I hope to eventually be able to call C# methods directly from within AHK. Is this in the works?


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 5th, 2009, 2:58 am 
Offline

Joined: November 5th, 2009, 2:47 am
Posts: 2
It's really a great job! I'm so interested at it.
But when I'm trying to compile IronAHK under ubuntu karmic with the latest src, I'll always get following error:

Code:
$ make
for dir in IronAHK Rusty Scripting Tests; do \
      for sub in "bin" obj; do \
         if [ -d "${dir}/${sub}" ]; then rm -R "${dir}/${sub}"; fi \
      done; \
   done;
mdtool build "--configuration:Release" "IronAHK.sln"
MonoDevelop Build Tool
Loading solution: IronAHK.sln
   Loading solution: IronAHK.sln
      Loading projects ..
      ERROR: Could not load solution: IronAHK.sln. Could not set property
      'Policies' in type 'Solution'
Could not set property 'Policies' in type 'Solution'
FATAL ERROR [2009-11-05 09:47:58Z]: System.InvalidOperationException: Could not set property 'Policies' in type 'Solution' ---> System.InvalidOperationException: Cannot deserialise unregistered policy name 'ChangeLogPolicy'
  at MonoDevelop.Projects.Policies.PolicyService.GetRegisteredType (System.String name) [0x00000]
  at MonoDevelop.Projects.Policies.PolicyService.DiffDeserialize (MonoDevelop.Core.Serialization.DataNode data) [0x00000]
  at
  ...


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 5th, 2009, 8:22 am 
Offline
User avatar

Joined: August 11th, 2004, 1:47 am
Posts: 5347
Location: UK
JoeSchmoe wrote:
I would be able to use Rusty to call the built-in AHK functions that I'm already comfortable with from my C# code. Am I right in this? Would the syntax be cumbersome?
Yes, IronAHK was designed to be modular for this purpose. You can take the DLL or source code of Rusty and include it in any .NET application. Calling them is as simple as Core.MsgBox(...), Core.DllCall(...) etc. You can even host the scripting engine to allow your users to interface with your application using powerful ahk syntax.

JoeSchmoe wrote:
I hope to eventually be able to call C# methods directly from within AHK. Is this in the works?
Calling other C# managed methods is easy with reflection and is part of the DLR spec which I hope to implement in future.

chrisguoado wrote:
when I'm trying to compile IronAHK under ubuntu karmic with the latest src, I'll always get following error:
Open IronAHK.sln in an editor and comment out (with a #) the lines starting with GlobalSection(MonoDevelopProperties) = preSolution all the way down to EndGlobalSection. I will try to fix this bug for older versions of MD soon.

_________________
GitHubScriptsIronAHK Contact by email not private message.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 5th, 2009, 9:40 am 
Offline

Joined: November 5th, 2009, 2:47 am
Posts: 2
Thanks a lot! It works.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 6th, 2009, 5:12 am 
Offline

Joined: November 6th, 2009, 5:11 am
Posts: 1
Hi titan, maybe you can help me with building it on Ubuntu as well, I get the following errors (monodevelop and mono-jit installed):

Code:
$make
for dir in IronAHK Rusty Scripting Tests; do \
      for sub in "bin" obj; do \
         if [ -d "${dir}/${sub}" ]; then rm -R "${dir}/${sub}"; fi \
      done; \
   done;
mdtool build "--configuration:Release" "IronAHK.sln"
MonoDevelop Build Tool
FATAL ERROR [2009-11-05 23:09:20Z]: System.Exception: Unknown option 'configuration'
  at MonoDevelop.Projects.BuildTool.ReadArgument (System.String argument) [0x00000]
  at MonoDevelop.Projects.BuildTool.Run (System.String[] arguments) [0x00000]
  at MonoDevelop.Core.ApplicationService.StartApplication (System.String appId, System.String[] parameters) [0x00000]
make: *** [all] Error 255


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 6th, 2009, 10:24 am 
Offline
User avatar

Joined: August 11th, 2004, 1:47 am
Posts: 5347
Location: UK
mike_mo wrote:
I get the following errors (monodevelop and mono-jit installed):
Looks like you're running an older version of monodevelop, you need at least version 2.0 (default in ubuntu karmic and debian squeeze).

_________________
GitHubScriptsIronAHK Contact by email not private message.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 6th, 2009, 5:15 pm 
Titan wrote:
mike_mo wrote:
I get the following errors (monodevelop and mono-jit installed):
Looks like you're running an older version of monodevelop, you need at least version 2.0 (default in ubuntu karmic and debian squeeze).


Still not working. Fresh Ubuntu 9.10 install, Monodevelop 2.0 fresh install. Proper lines commented out on IronAHK.sln and I still get fatal errors.


Report this post
Top
  
Reply with quote  
 Post subject:
PostPosted: November 6th, 2009, 6:54 pm 
Offline

Joined: November 6th, 2009, 6:49 pm
Posts: 3
Hi Titan,

I wonder if you could help me figure out what the problem is with my attempt to install IronAHK on Ubuntu Jaunty.

I installed the latest version of various monodevelop libraries, downloaded IronAHK and ran "make install all".

First I got an error that was corrected by commenting out the Global section as you recommended elsewhere.

After I got past that error, I got a new one:

Code:
    /mainline/Scripting/IACodeProvider.cs(100,32): error CS1502:
    The best overloaded method match for
    `System.CodeDom.Compiler.CompilerError.CompilerError(string, int, int,
    string, string)' has some invalid arguments /usr/lib/mono/gac/System
    /2.0.0.0__b77a5c561934e089/System.dll (Location of the symbol related
    to previous error) /mainline/Scripting/IACodeProvider.cs(100,32):
    error CS1503: Argument `#4' cannot convert `int' expression to type `string'

I'm not able to get any further with my installation of IronAHK.

Would appreciate any tips on what to try next.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 6th, 2009, 8:19 pm 
Offline
User avatar

Joined: August 11th, 2004, 1:47 am
Posts: 5347
Location: UK
The two bugs have been fixed. If you have the source already run git pull to update, or run the following commands to get started from scratch:

Code:
$ sudo apt-get install git-core monodevelop make nunit # install all required dependencies for debug builds
$ git clone git://gitorious.org/ironahk/mainline.git ironahk # download source
$ cd ironahk
$ git pull # update source
$ make
$ cd IronAHK/bin/Release
$ cp ../../../Tests/Scripting/Code/ComplexExpression.ia . # copy over a test script
$ mono IronAHK.exe /out test.exe ComplexExpression.ia # compile the script
$ mono test.exe & # run compiled script

_________________
GitHubScriptsIronAHK Contact by email not private message.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 6th, 2009, 10:25 pm 
Offline

Joined: November 6th, 2009, 6:49 pm
Posts: 3
Thanks Titan! It worked.

I tried replacing your code from ComplexExpression.ia with this code and recompiling:

Code:
Numpad1::
Send {Alt Down}
Sleep, 1000
Send {Tab}
Loop
{
   GetKeyState, state, Numpad1, P
   if state = U
      break
   Sleep, 1000
   Send {Tab}
}
Send {Alt Up}
return


I replaced the contents of the script ComplexExpression.ia with the code above and then copied it over just as you had done:

Code:
$ cd IronAHK/bin/Release
$ cp ../../../Tests/Scripting/Code/ComplexExpression.ia . # copy over a test script
$ mono IronAHK.exe /out test.exe ComplexExpression.ia # compile the script


After the last command above, I see this output:

Code:
Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object
  at IronAHK.Scripting.Compiler.CompileAssemblyFromDomBatch (System.CodeDom.Compiler.CompilerParameters options, System.CodeDom.CodeCompileUnit[] compilationUnits) [0x00000]
  at IronAHK.Scripting.IACodeProvider.CompileAssemblyFromDom (System.CodeDom.Compiler.CompilerParameters options, System.CodeDom.CodeCompileUnit[] compilationUnits) [0x00000]
  at IronAHK.Scripting.IACodeProvider.CompileAssemblyFromReader (System.CodeDom.Compiler.CompilerParameters options, System.IO.TextReader[] readers) [0x00000]
  at IronAHK.Scripting.IACodeProvider.CompileAssemblyFromFile (System.CodeDom.Compiler.CompilerParameters options, System.String[] fileNames) [0x00000]
  at IronAHK.Program.Main (System.String[] args) [0x00000]


Any idea what went wrong here?


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 7th, 2009, 12:07 am 
Offline
User avatar

Joined: August 11th, 2004, 1:47 am
Posts: 5347
Location: UK
The compiler is still incomplete so not all scripts will work yet. You can create hotkeys from C# or VB.NET code using the IronAHK.Rusty.Linux.PoliteRegister class although I don't think this is what you want.

_________________
GitHubScriptsIronAHK Contact by email not private message.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 7th, 2009, 1:41 am 
Offline

Joined: November 6th, 2009, 6:49 pm
Posts: 3
Titan,

Thanks for the feedback.

We were discussing IronAHK as a possible solution to a problem on Ubuntu:

http://superuser.com/questions/62892/how-to-switch-applications-in-ubuntu-gnome-using-an-alternative-keystroke-to-the

Maybe I'll check back later on when it's more complete.

Regards,
lipton


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 9th, 2009, 4:17 pm 
Offline

Joined: February 17th, 2008, 5:01 pm
Posts: 303
Titan wrote:
JoeSchmoe wrote:
I would be able to use Rusty to call the built-in AHK functions that I'm already comfortable with from my C# code. Am I right in this? Would the syntax be cumbersome?
Yes, IronAHK was designed to be modular for this purpose. You can take the DLL or source code of Rusty and include it in any .NET application. Calling them is as simple as Core.MsgBox(...), Core.DllCall(...) etc. You can even host the scripting engine to allow your users to interface with your application using powerful ahk syntax.

JoeSchmoe wrote:
I hope to eventually be able to call C# methods directly from within AHK. Is this in the works?
Calling other C# managed methods is easy with reflection and is part of the DLR spec which I hope to implement in future.
I really love AHK and have written thousands of lines of AHK code. I think that we are all aware, though, that there have been a number of pushes in the past to make AHK more like some of the more "grown up" languages that we may be used to. For example, objects, a simpler and more consistent syntax, etc. In my mind, the tremendous and ongoing growth of AHK shows that these concerns, while valid, don't outweigh the strengths of the language.

In general, it seems like the potential for C# and CLR integration really sets this project apart and is a unique feature for it. In my opinion, the more integration we can have between IA and C# and between IA and CLR, the better. Microsoft seems to have poured huge resources into C# and the CLI, and they don't seem to be going away.

Since C# is a fully OO language and since the CLI is fully object oriented, would it be possible for you to use integration with C# and CLR in IA as a way to bring some of the features that I mentioned in the first paragraph into AHK? For example, programmers will already need to know something about how to call objects in C# and CLI to take advantage of the interoperability features of IA. Would it be possible to use some of that same syntax within IA?

For those who don't already know:
    IA=Iron AutoHotkey
    CLI=Common Language Infrastructure, part of .net
    CLR=Common Language Runtime, the runtime that implements CLI.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 9th, 2009, 11:03 pm 
Offline
User avatar

Joined: August 11th, 2004, 1:47 am
Posts: 5347
Location: UK
JoeSchmoe wrote:
would it be possible for you to use integration with C# and CLR in IA as a way to bring some of the features that I mentioned in the first paragraph into AHK
Yes. In general, if your C# code is CLSCompliant it will work with IA seamlessly. This type of integration happens already with Rusty (the default command set) which is written entirely in C# and is independent of the scripting engine.

_________________
GitHubScriptsIronAHK Contact by email not private message.


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic This topic is locked, you cannot edit posts or make further replies.  [ 87 posts ]  Go to page Previous  1, 2, 3, 4, 5, 6  Next

All times are UTC [ DST ]


Who is online

Users browsing this forum: No registered users and 3 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group