THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 29/03/2010 at 06:34, xxxxxxxx wrote:
Cinema 4D Version: 11.5
Platform: Windows ;
Language(s) : C.O.F.F.E.E ;
I have a script that makes a dialog,
Its posible to add a bitmap (a logo) or a bitmapbutton ? in the script an as easy way as that ?
Another question (not related to previus topic) :
Lets say a dialog have a add and remove button to remove or add items in a combobox or list, is that posible? and it automatically updates de list of items or we have to reload the dialog or something?...
On 29/03/2010 at 12:06, xxxxxxxx wrote:
As far as I know, there's no direct possibility to add a bitmap to a GeUserDialog in Coffee. But you could use the member function AddUserArea() to add a GeUserArea. The GeUserArea class offers the member function DrawBitmap(), which should do what you want.
On 29/03/2010 at 16:16, xxxxxxxx wrote:
Any example please?
On 30/03/2010 at 01:09, xxxxxxxx wrote:
Sorry, I code in C++.
No Coffee examples from me
On 30/03/2010 at 08:38, xxxxxxxx wrote:
Sorry if this question is too silly but:
Is not posible to put c++ code inside a coffe script?
On 30/03/2010 at 10:35, xxxxxxxx wrote:
Of course not. Otherwise it would be called a C++ script.
On 30/03/2010 at 14:02, xxxxxxxx wrote:
or maybe a Zoffee script.. sorry, couldn´t resist.
For examples, search the forum. You will have enough information and example code to create a user area.
Generally you should first have a look at basic programming operations in a procedural or object oriented language. It will save you time and head aches.
On 31/03/2010 at 05:12, xxxxxxxx wrote:
Yes, bitmaps or bitmap buttons are realized through user areas in dialogs.
Here is a simple example showing the basic use of user areas. It's just a pure red bitmap but you can use the BaseBitmap loading methods to load a custom bitmap.
class MyUserArea : GeUserArea
var x = GetUserWidth();
var y = GetUserHeight();
bmp = new(BaseBitmap,x,y);
class MyDialog : GeModalDialog
ua = new(MyUserArea,5000,this);
var d = new(MyDialog);
Please check the COFFEE documentation for explainations of the classes.