Archicad C++ API
About Archicad add-on development using the C++ API.
SOLVED!

Picture boxes or canvas tools in Dialogs?

Mihalcea Bogdan
Contributor
Hello!
Which part of the API Reference I need to read about picture boxes?
Is there any "canvas" like elements for Archicad?
I really need a picture container or an canvas container where I can display and interact a .PNG, or a .SVG file.
After some user input is made, the AddOn will create a query on a database(online) which will result in an image, after that i need to update that image and so on ...

Is there any possibility to actually draw on the Dialog box?

I attached a picture where I would like to have a picture box or a canvas element so you can have an ideea. .
A C# example:
10 REPLIES 10
Mihalcea Bogdan
Contributor
Viktor wrote:
It's a general rule for all applications that they should draw only when the operating system requests them to do so. In your case it means that you can draw only in the UserItemUpdate function, so the context can't be reused. Fortunately, you can request the operating system to redraw. Call the userItem.Redraw (true, true) function which will force the call of UserItemUpdate.
I did observe this behaviour, I thought that this kind of approach is wrong(I have some JavaScript webgl background where the context is a variable accessible by any function). Thank you again!

Didn't find the answer?

Check other topics in this Forum

Back to Forum

Read the latest accepted solutions!

Accepted Solutions

Start a new conversation!