Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Toolbar button refresh

I have a flyout toolbar that is set up with "own icon" = off so that the icon displayed on the associated static toolbar corresponds to the last selected button on the flyout.  I'd like to have the icon in the static toolbar automatically update when a drawing is opened to show the icon corresponding the setting stored in the drawing being opened.  I can do this with vla-setbitmaps, but it is slow -- the toolbar disappears for about two seconds before it is redrawn. 

Is there a way to force a toolbar to update/redraw that is faster? 

Thanks.

Comments

  • Are you actually able to change which flyout tool is 'current'? It is my understanding that the setbitmaps method *only* changes the bitmap.
  • Roy,

    The intent is to be sure that the visible icon always shows the actual scale of the drawing.  After a drawing is opened I use the fly-out to change scales when necessary, and the icon in the static toolbar changes when a scale is selected in the flyout.  You are correct that vla-setbitmaps only changes the visible icon, but that's not a problem -- there is lisp code that takes care of keeping settings coordinated.  It is when I open a new drawing that I have a problem -- the visible icon shows the scale from the previous drawing instead of the scale in the drawing just opened.  I should point out that all my drawings are model space only and that I have lisp code that closes any open drawing(s) before calling the file open dialog for a new drawing.  It's as close as I can come to the SDI mode for Autocad 2004.
  • I just did a quick test and experience no noticeable delay. Maybe your bitmap files are to blame? I have tested with small .png images and small and large .bmp images (small=16x16 and large=32x32). BricsCAD V14.2.17, default menu.
  • All the bitmaps are custom 16x16 bmp.  They are on a server, but moving them to a local drive does not change things.  The toolbar disappears for up to three seconds, then is redrawn.  The other computers in the office also have a visible delay, but it does not seem to be as long.  This is the last icon on the toolbar, which has 19 buttons.  I've tried moving the flyout to a single button toolbar and I still see the same delay.  At least it is not as long as the delay when I open the mtext editor for the first time -- that runs about 30 seconds.  
  • I have tested again. This time also with a docked toolbar.

    Docked toolbar:
    It is noticeable that the toolbar is redrawn, but it all happens in a flash.
    Benchmark time: 75 milliseconds.

    Undocked toolbar:
    It is not noticeable that the toolbar is redrawn. But if the toolbar was just undocked it will become 4px longer (strange).
    Benchmark time: 103 milliseconds.
  • But if the toolbar was just undocked it will become 4px longer (strange).


    Assuming V15, Perhaps this is due to updating of the current workspace in the CUI? The Workspace captures the current toolbar states. I would think you could confirm this by setting WSAUTOSAVE OFF, then re-run your tests.

    Regards,

    Jason Bourhill

    CAD Concepts 


  • @ Jason:
    I don't think it is related to workspaces. It seems to affect toolbars that were previously docked vertically.

    A simple test (BricsCAD V14.2.17):
    1. Open BC.
    2. Undock a vertical toolbar.
    3. Restart BC.
    4. Undock another vertical tool.
    5. Align the right most edge of the last toolbar with that of the first.
    6. Restart BC.
    7. The last toolbar is now longer.
  • If I recall correctly Bricscad changed from from "old fashioned" toolbars and pop-ups to a widget system a few years ago.  I'm not a fan.  The original system worked really well and never seemed slow.  What I remember is that pop-ups appeared to paint instantaneously, and fly-outs did not have a visible delay between when I clicked on the parent button and when the fly-out appeared.  With the widget system I watch every pop-up paint from left to right and I have to wait for fly-outs to open.  The delays are not long, but they are enough to throw off my rhythm. 

    This might be a good thing for Owen to look at.  His QuikPik was a utility I would not have been without back when I ran Autocad.  I really miss the toolbar locking and the quick buttons.  I'd be first in line to buy "QuikPik for Bricscad".
  • If I recall correctly Bricscad changed from from "old fashioned" toolbars and pop-ups to a widget system a few years ago.  I'm not a fan.  The original system worked really well and never seemed slow.  What I remember is that pop-ups appeared to paint instantaneously, and fly-outs did not have a visible delay between when I clicked on the parent button and when the fly-out appeared.  With the widget system I watch every pop-up paint from left to right and I have to wait for fly-outs to open.  The delays are not long, but they are enough to throw off my rhythm. 

    This might be a good thing for Owen to look at.  His QuikPik was a utility I would not have been without back when I ran Autocad.  I really miss the toolbar locking and the quick buttons.  I'd be first in line to buy "QuikPik for Bricscad".
  • As Joe said in another thread there seems to be a problem with the forum today.  For both my recent posts I received a "Service not available.  Please try again later." message.
This discussion has been closed.
Origami
Origami is the Japanese word for paper folding. ORI means to fold and KAMI means paper and involves the creation of paper forms usually entirely by folding.

Powered by VanillaForums, Designed by Steam