6 comments
Comment actions Permalink

It's not possible with the current API. Just curious: why do you need it?

--
Valentin Kipiatkov
JetBrains, Inc
http://www.intellij.com
"Develop with pleasure!"

"Kelly Ray Jensen" <kellyrayj@myrealbox.com> wrote in message
news:aq7pkf$i10$1@is.intellij.net...

Is it possible to invoke undo (Ctrl-z) using the openapi?

>

If so, how?

>

thanks,

>

Kelly



0
Comment actions Permalink

For my Vi plugin.

thanks,

Kelly

On Wed, 06 Nov 2002 04:22:41 -0800, Valentin Kipiatkov wrote:

It's not possible with the current API. Just curious: why do you need it?

--
Valentin Kipiatkov
JetBrains, Inc
http://www.intellij.com
"Develop with pleasure!"

"Kelly Ray Jensen" <kellyrayj@myrealbox.com> wrote in message
news:aq7pkf$i10$1@is.intellij.net...

>> Is it possible to invoke undo (Ctrl-z) using the openapi?
>>
>> If so, how?
>>
>> thanks,
>>
>> Kelly

0
Comment actions Permalink

For my Vi plugin.


But what does it do so that it needs to invoke undo?

--
Valentin Kipiatkov
JetBrains, Inc
http://www.intellij.com
"Develop with pleasure!"

"Kelly Ray Jensen" <kellyrayj@myrealbox.com> wrote in message
news:aqb8c2$eed$1@is.intellij.net...

For my Vi plugin.

>

thanks,

>

Kelly

>

On Wed, 06 Nov 2002 04:22:41 -0800, Valentin Kipiatkov wrote:

>

It's not possible with the current API. Just curious: why do you need

it?

>

--
Valentin Kipiatkov
JetBrains, Inc
http://www.intellij.com
"Develop with pleasure!"

>

"Kelly Ray Jensen" <kellyrayj@myrealbox.com> wrote in message
news:aq7pkf$i10$1@is.intellij.net...

>> Is it possible to invoke undo (Ctrl-z) using the openapi?
>>
>> If so, how?
>>
>> thanks,
>>
>> Kelly

>


0
Comment actions Permalink

Under Vi pressing the 'u' key invokes undo. I have a ViTypedActionHandler
that checks which key was pressed. If the key was 'u' then I would invoke
undo.

On another note, is it possible to discover which meta keys (Ctrl, shift)
were pressed? The TypedActionHandler gives you the character typed but I
haven't found how to tell if any meta keys were pressed also.

thanks,

Kelly

On Thu, 07 Nov 2002 07:09:00 -0800, Valentin Kipiatkov wrote:

>> For my Vi plugin.


But what does it do so that it needs to invoke undo?

--
Valentin Kipiatkov
JetBrains, Inc
http://www.intellij.com
"Develop with pleasure!"

0
Comment actions Permalink

Under Vi pressing the 'u' key invokes undo. I have a ViTypedActionHandler
that checks which key was pressed. If the key was 'u' then I would invoke
undo.


You might try to find undo action by its id and invoke it directly, although
I'm not sure it will work find.

>

On another note, is it possible to discover which meta keys (Ctrl, shift)
were pressed? The TypedActionHandler gives you the character typed but I
haven't found how to tell if any meta keys were pressed also.


TypedActionHandler is only invoked for characters typed in the editor, not
special key combinations.

--
Valentin Kipiatkov
JetBrains, Inc
http://www.intellij.com
"Develop with pleasure!"

"Kelly Ray Jensen" <kellyrayj@myrealbox.com> wrote in message
news:aqe0jm$otq$1@is.intellij.net...

Under Vi pressing the 'u' key invokes undo. I have a ViTypedActionHandler
that checks which key was pressed. If the key was 'u' then I would invoke
undo.

>

On another note, is it possible to discover which meta keys (Ctrl, shift)
were pressed? The TypedActionHandler gives you the character typed but I
haven't found how to tell if any meta keys were pressed also.

>

thanks,

>

Kelly

>

On Thu, 07 Nov 2002 07:09:00 -0800, Valentin Kipiatkov wrote:

>

>> For my Vi plugin.
>

But what does it do so that it needs to invoke undo?

>

--
Valentin Kipiatkov
JetBrains, Inc
http://www.intellij.com
"Develop with pleasure!"



0
Comment actions Permalink

I created an EditorAction that writes into a file. I want to provide the user the opportunity to unwrite those changes. I would like to treat those changes as first class objects, and not just Undoables on the undo stack.

In other words, in most cases, the user will not want to undo everything that happened after I wrote to their file, but rather just undo what the EditorAction wrote to their file.

Is this possible?

0

Please sign in to leave a comment.