This a some how old post, but I haven't found the complete solution, appreciate all your help.
Klaas Holwerda escribió: > SetEditable(bool editable) is to disable editing on an object and all its > children object. > But hierarchical object like a2dPlot, can only be edited inside(children) if > the object itself is editable. > So you must set the children non editable. > > Next to that you do not want to edit a2dPlot itself for certain features. > > PROPID_Allowrotation.SetPropertyToObject( editcopy, false ); > PROPID_Allowsizing.SetPropertyToObject( editcopy, false ); > PROPID_Allowskew.SetPropertyToObject( editcopy, false ); > > That should i think do more or less what you want. > That worked, but not complete for example the user can move the plot and selected, the idea is to disable this features and just alow the user to changed the points for the graph. Any idea to get that working?. > Happens in: > > void a2dVertexCurve::OnCanvasObjectMouseEvent( a2dCanvasObjectMouseEvent& > event ) > > I did add an extra flag: > > > //! these flags define how (points on) curves can be moved/edited > enum a2dCurveEditFlags > { > a2dCURVES_EDIT_NORMAL = 0x0001, /*!< points can be moved > in any direction */ > a2dCURVES_EDIT_FIXED_X = 0x0002, /*!< points have fixed x > coord. */ > a2dCURVES_EDIT_FIXED_Y = 0x0004, /*!< points have fixed y > coord. */ > a2dCURVES_EDIT_ALLOW_ADD = 0x0008, /*!< allow adding new > points to curve */ > a2dCURVES_EDIT_DEFAULT = a2dCURVES_EDIT_NORMAL > }; > > And in a2dVertexCurve::OnCanvasObjectMouseEvent. > > if (!(m_editmode & a2dCURVES_EDIT_NORMAL)) > > Will check it in within 10 days, since my internet connection is down at home > :-( > > Klaas > > I checked outthe new cvs, and found this feature implemented, but in the reality it didn't worked as it should be, or at least I don't know who can I get to work. For example I need the FIXED_Y and not to allow add points in the graph, so I did this: a2dVertexCurve* curve = new a2dVertexCurve(); curve->SetEditMode(4); And then set the points and all that, but it didn't work. I really appreciate your help and work Klass, I really like to help you but it seems my knowledge it's to down, so first I keep in learning and I can help you with something, for the moment I'll begin to write some docs about the advances I have have with the library. Ibraim ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Wxart2d-users_dev mailing list Wxart2d-users_dev@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wxart2d-users_dev