.NET

Reply
*Maksim Sestic
Message 1 of 3 (126 Views)

PalleteSet + GetPoint glitch in 06

126 Views, 2 Replies
07-19-2006 04:07 AM

Dear all,

 

My colleague stumped onto the ACAD2006 glitch
which is easily reproducable. There's a non-transparent
command that displays PalleteSet docker (if not visible) and
immediately enters an Editor.GetPoint() Do...While loop. At the moment
PalleteSet gets displayed (if previously invisible), GetPoint somehow returns
PromptStatus.Cancel result (?!), forcibly cancelling GetPoint in
progress.

 

Overall processing goes
like:

 

1) User issues a command

2) Is PalleteSet visible? If not, display
it

3) Enter GetPoint loop and let the user pick
several points

 

At the step 2, if PaletteSet is not visible and
needs to get displayed, my GetPoint loop in step 3 somehow receives a
Cancel. 

 

This is tricky, since docker state should not
affect Editor in any way. Is there something in PaletteSetStyles or
CommandFlags we should take special care of?

 

With kindest regards,

Maksim Sestic

 

 
*Tony Tanzillo
Message 2 of 3 (126 Views)

Re: PalleteSet + GetPoint glitch in 06

07-19-2006 04:31 AM in reply to: *Maksim Sestic
I don't think that's going to work.

If the palette is docked, then when it is shown,
the size of drawing view window changes and
if you know anything about that, it cancels out
any pending input prompt.

Essentially it is no different than when you
resize the AutoCAD window after doing this:

Command: (setq x (getpoint "\nResize the window now"))

If you follow that, you'll see "*cancel*" appear
on the command line and the outstanding prompt
issued by the call to getpoint is cancelled, and
you are back at the Command: prompt.

--
http://www.caddzone.com

AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005/2006/2007
http://www.acadxtabs.com

"Maksim Sestic" wrote in message news:5241231@discussion.autodesk.com...
Dear all,

My colleague stumped onto the ACAD2006 glitch which is easily reproducable. There's a non-transparent command that displays PalleteSet docker (if not visible) and immediately enters an Editor.GetPoint() Do...While loop. At the moment PalleteSet gets displayed (if previously invisible), GetPoint somehow returns PromptStatus.Cancel result (?!), forcibly cancelling GetPoint in progress.

Overall processing goes like:

1) User issues a command
2) Is PalleteSet visible? If not, display it
3) Enter GetPoint loop and let the user pick several points

At the step 2, if PaletteSet is not visible and needs to get displayed, my GetPoint loop in step 3 somehow receives a Cancel.

This is tricky, since docker state should not affect Editor in any way. Is there something in PaletteSetStyles or CommandFlags we should take special care of?

With kindest regards,
Maksim Sestic
*Maksim Sestic
Message 3 of 3 (126 Views)

Re: PalleteSet + GetPoint glitch in 06

07-19-2006 04:55 AM in reply to: *Maksim Sestic

Thanks for the tip, it saved me hours of trying
this and that.

 

There is a simple workaround, though, but I just
tried to make it more straightforward. I'm checking if docker is
displayed for the first time or being resized/undocked, and if it is then I'm
forcibly pushing PromptStatus.OK, while removing resulting "point"
from the stack - thus saving my GetPoint loop structure.

 

Now, it seems that current approach proposes
activating commands from within active docker (i.e. clicking a button). On the
other hand, I'm using that particular docker as a helper tool which assists
user set certain drafting options while picking points. There's plenty of
options and I tried to avoid command-line Keywords implementation since it's
rather unsuitable.

 

Regards,

Maksim Sestic

 

 

I don't think
that's going to work.

If the palette is docked, then when it is
shown,
the size of drawing view window changes and
if you know anything
about that, it cancels out
any pending input prompt.

Essentially it is
no different than when you
resize the AutoCAD window after doing
this:

Command: (setq x (getpoint "\nResize the window now"))

If
you follow that, you'll see "*cancel*" appear
on the command line and the
outstanding prompt
issued by the call to getpoint is cancelled, and
you
are back at the Command: prompt.

--

href="http://www.caddzone.com">
size=2>http://www.caddzone.com



size=2>AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005/2006/2007

href="http://www.acadxtabs.com">
size=2>http://www.acadxtabs.com



size=2>"Maksim Sestic" <

face=Verdana size=2>info@geoinova.com
>
wrote in message

face=Verdana size=2>news:5241231@discussion.autodesk.com

face=Verdana size=2>...
Dear all,
 
My colleague stumped onto the
ACAD2006 glitch which is easily reproducable. There's a non-transparent command
that displays PalleteSet docker (if not visible) and immediately enters an
Editor.GetPoint() Do...While loop. At the moment PalleteSet gets displayed (if
previously invisible), GetPoint somehow returns PromptStatus.Cancel result (?!),
forcibly cancelling GetPoint in progress.
 
Overall processing goes
like:
 
1) User issues a command
2) Is PalleteSet visible? If not,
display it
3) Enter GetPoint loop and let the user pick several
points
 
At the step 2, if PaletteSet is not visible and needs to get
displayed, my GetPoint loop in step 3 somehow receives a Cancel.

 
This is tricky, since docker state should not affect Editor in any
way. Is there something in PaletteSetStyles or CommandFlags we should take
special care of?
 
With kindest regards,
Maksim
Sestic
Announcements
Are you familiar with the Autodesk Expert Elites? The Expert Elite program is made up of customers that help other customers by sharing knowledge and exemplifying an engaging style of collaboration. To learn more, please visit our Expert Elite website.
Need installation help?

Start with some of our most frequented solutions or visit the Installation and Licensing Forum to get help installing your software.