- I would like to serialize a multiline textnode as xml with multiple text nodes equal to each line in the textnode. How can I do this?
- I have the same print bug as others i.e. text rescales when printing textnodes
- I would like selections of nodes and links to be sorted left to right and top to bottom and the topmost left node be the primary object
- I don’t know of an easy way to do this in general. Wrapping and clipping depend a lot on the particular font and size of the GoText and the display device. We had to do something similar for SVG support and for PocketPC support, but the implementations were quite complicated and quite different from each other.
Of course in the simplest cases, you can just look for embedded newlines, but I assume you are already doing that.
- For a fix, send us e-mail.
- That’s interesting. Did you want to make sure the objects in a GoSelection were always sorted? That would mean you would need to be constantly resorting as objects moved around or were resized.
Better yet, why is the order important? The order is not guaranteed at this time. It does use both an ArrayList and a Hashtable, but the ArrayList and its ordering are not exposed.
Perhaps you just need to implement a method that sorts an array of objects in the manner you like, and use that whenever you do something that requires such ordering.
- Is there any way to capture the lines as displayed in the TextBox editor?
- I will send you an email when I get back to work on Thursday
- I have implemented somecode to evenly space nodes horizontally or vertically (did the sort myself). Just thought it might make a good feature. NB It is annoying if Primary selection is a link when aligning nodes.
- Any answer to my Link label problem (mid Decembeer)?
- Not that I can think of at this moment.
- Hmm, yes, it would be better if the code that cared about the PrimarySelection not being a link automatically chose the first non-link as if it were the “primary” object. But all of that is sample code, not part of the GoDiagram library.
You could implement a GoView.ObjectGotSelection and ObjectLostSelection event handler that would automatically make sure the GoSelection.Primary object (if any) was always a “valid” object, such as the node that is at the most top-left position.
- No, looking at that topic, it doesn’t appear as if we could reproduce or even understand what the problem was. But I can imagine that having the GoLabeledLink.MidLabel object positioned in the middle segment of the link would not appear about midway between the two ports. I think that’s more likely if AvoidsNode is true. You can always override GoLabeledLink.LayoutMidLabel method.