[Sikuli-driver] [Question #697681]: select all text and copy to clipboard

2021-06-24 Thread Ben Dix
New question #697681 on SikuliX:
https://answers.launchpad.net/sikuli/+question/697681

Hey Folks,

at the end of my script, my console output must be saved to a txt file.
right now I solved this by clicking on the top left of the java window, finding 
the buttons by images to do so.
The filename is generated by time and date stamps.
working, but takes a bit time...

I would prefer to do so by commands, not by image search...

I already tried to activate the java window and do  type('a', Key.CTRL) to 
select all, but this action fails with the output:

[log] ( Ctrl )  TYPE "a"
[error] script [ Test_Enviroment ] stopped with error in line 66
[error] java.lang.IllegalArgumentException ( 
java.lang.IllegalArgumentException: Key: Not supported character: a )
[error] --- Traceback --- error source first
line: module ( function ) statement
66: main (   ) type('a', Key.CTRL)
[error] --- Traceback --- end --

any advice how to use the select all shortcut inside the active java (output) 
window of my sikuli script?

thx for reading.

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for SikuliX.

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #697681]: select all text and copy to clipboard

2021-06-24 Thread RaiMan
Question #697681 on SikuliX changed:
https://answers.launchpad.net/sikuli/+question/697681

Status: Open => Answered

RaiMan proposed the following answer:
Just tried on my macOS with 2.0.5: (thought you are on macOS, not
Windows!?)

click() # make window foreground/active
wait(1)
type("a", Key.CMD) # select all text

having a text window centred on the screen.

The text is selected as expected.

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for SikuliX.

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #697681]: select all text and copy to clipboard

2021-06-24 Thread Ben Dix
Question #697681 on SikuliX changed:
https://answers.launchpad.net/sikuli/+question/697681

Ben Dix posted a new comment:
Hey RaiMan, thx for your reply.

I am on Mac AND Win 😄

It is working fine on Mac, looks like it is something about the java
console in win.

Feels like the java output console is the problem...
is it possible, that the key shortcuts inside the java output console try to 
trigger the IDE ?

the log confirms, that the action happened, but maybe this command leads
to nowhere...

[log] ( Ctrl ) TYPE "a"

would be great if anyone can test this on a win machine 😄 
it is not a virtual machine, it is a physical win10 environment.

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for SikuliX.

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #697681]: select all text and copy to clipboard

2021-06-24 Thread RaiMan
Question #697681 on SikuliX changed:
https://answers.launchpad.net/sikuli/+question/697681

RaiMan requested more information:
ok ;-)

what is " java console"?

I can test on Windows also - no problem :-)

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for SikuliX.

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #697681]: select all text and copy to clipboard

2021-06-24 Thread Ben Dix
Question #697681 on SikuliX changed:
https://answers.launchpad.net/sikuli/+question/697681

Ben Dix posted a new comment:
I start sikuli by executing cmd command java -jar ...\sikulixide-2.0.5.jar -c
the cmd window , that stays in the background and that prints all my output is 
my so called java console 😄 
sorry for my individual naming 😄

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for SikuliX.

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #697681]: select all text and copy to clipboard

2021-06-24 Thread RaiMan
Question #697681 on SikuliX changed:
https://answers.launchpad.net/sikuli/+question/697681

RaiMan posted a new comment:
indeed very individual :-)))

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for SikuliX.

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #697681]: select all text and copy to clipboard

2021-06-24 Thread RaiMan
Question #697681 on SikuliX changed:
https://answers.launchpad.net/sikuli/+question/697681

RaiMan proposed the following answer:
Sorry, but I have to confirm, that the type() command does not work
against a command line window.

You might pipe the complete java command output to a file (> mylog.txt)
or use the print statement with the file option for the relevant
information.

SikuliX's user log is also an option.

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for SikuliX.

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #697681]: select all text and copy to clipboard

2021-06-29 Thread Ben Dix
Question #697681 on SikuliX changed:
https://answers.launchpad.net/sikuli/+question/697681

Status: Answered => Solved

Ben Dix confirmed that the question is solved:
thx RaiMan 😄 I can go on using the images to select all code of this
window 😄

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for SikuliX.

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp