Re: Question Re: WorkbookControlGUI object.



Jon:
Where is gtk.MessageDialog defined? I am writing in
'analysis-tools.c', I tried '#include <gtk/gtkmessagedialog.h>',
aswell as <gui-util.h>, but still make claims gtk, messagedialog and
such are undeclared. 

Sorry, I was in pattern matching mode, and assumed that you guys were
using Python.

Nakai:
I tried -
Workbook *wb = val->v_range.cell.a.sheet->workbook;
WorkbookView *wbv = g_ptr_array_index (wb->wb_views, 0);
WorkbookControlGUI *wbcg = (WorkbookControlGUI) g_ptr_array_index
(wbv->wb_controls, 0); 

to get the WorkbookGUI object, but I get make claiming I am
'dereferencing pointer to incomplete type', and 'conversion to
non-scalar type requested' for the two lines respectivly. 


Am I doing something stupid?

You are using a dialog to interact with the user, aren't you. That dialog
knows which WorkbookControlGUI it belongs to. Dialogs typically wrap
their state in a struct which is passed as the last parameter to a
callback. You should make sure that your WorkbookControlGUI can be
reached in this way.

Going from workbook would sort of work, but breaks Gnumeric's
architecture. There are many views for each workbook, and you shouldn't
just choose one at random. 

Show me some code if this info is too general to be helpful.

Regards

Jon Kåre



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]