draw.io - how to link text from one shape to another? - draw.io

In draw.io, I was wondering if it is possible to link the text from a shape on one page to the text of another shape on another page, in a way it is done in Visio with SHAPETEXT, for example: =SHAPETEXT(Pages[PageName]!ShapeName.1!TheText). So that if the text is changed in the first shape, it would be changed in the second shape automatically.
Thanks!

Related

How to take a screenshot of a particular QWidget in a tab in QT and post it in another tab?

I have a tab that is to display data that is to be prepared for a report. Kind of like a preview. What I want is to take a screenshot of graph generated in another tab.
Kind of similar to scanning an image. So the initial tab generates 3 graphs under each other that fit in the screen. I basically want the screen shots of the graphs to post them along with the data in the second tab.
The second image is where I want the content of the first image to be posted. How do I go on about that?

Qt - Relation between two textedits

I've got a question about a TextEdit class in Qt.
I'm trying to create a Diff-like program in Qt. So far I'm using the QTextBlock with QTextCursor to color the changed lines on my QPlainTextEdit.
My question is - how can I create that 'spout' that shows the relations between two lines, just like in meld?
As you can see on the screenshot, 10 blue lines in the first file correspond to 4 blue lines in the second file
I think you're going to have to build your own custom widget, derived from QWidget, for that center section, and then handle the painting yourself. The tricky part will likely be the issue of informing the center widget where the colored lines are on each side (which will be related to how they're scrolled) so that it knows where to put the colored sections.

codename one - no way to set background image in list

I am new to codename one and I have tried for one and half day to fix my issue of,
a list with background image in each row.
Let me explain, I am having a list with some items(entries), I created renderer and name it appropriately. I set background correctly which is reflecting in designer (see image)
but when I run it on simulator/device , all formatting and designs are just invisible..!! (see red arrow pointing to simulator in image)
anyone have any idea ? why this is happening ?
Thanks,
Akash
It seems you didn't set the background correctly in the designer. Since the list items in the model within the designer are strings the renderer entries don't get overriden and so you see a separate UI.
To reproduce the issue in the designer click the items entry in the list property, remove everything and add a sample key/value hashtable pair. You would see all your design entries disappearing.
This might help you understand how to customize images and backgrounds here: http://www.codenameone.com/3/post/2013/12/deeper-in-the-renderer.html

How to draw a line (or arrow) from one object to another in run time using Qt

I have to design a GUI using Qt. I would like to draw multiple lines depicting relationships between two objects. It's the same idea as matching a word with a definition by drawing a straight line (which might be a diagonal) between the two.
In my case it is an a label (with image inside of it) that needs to be matched with another label.
So we have something like this - http://dl.dropbox.com/u/46437808/DrawLines.png
And I want to add lines to make it look something like this http://dl.dropbox.com/u/46437808/DrawLines2.png
I need to do this in run time because the relationship will be changing based on different factors.
Thanks!
Do you need interaction or is this just an image that the user needs to see based on other information? If it's just a static image, I would simply draw it onto a QImage and show it. That way you have complete control over how things are drawn. So you can either cache the relationship diagrams you need ahead of time, or just draw them on the fly onto the QImage based on the relationship that needs to be displayed at the time. You can look at Qt's painting example for some ideas on how to accomplish what you need.
If you need interactivity, I would probably go with the Graphics View Framework. This way if you need push buttons, check boxes, etc. for any reason you can use the QGraphicsProxyWidget to get them, or you can just make your own from QGraphicsItem subclasses.

how to add an image along with text in a button in MFC?

Am having a hard time in adding image along with a text in a Button..I know that it can be done by enabling the owner draw function with bitmapbutton class..But I dont want to that..so is ther anyother way that i can add an image along with text without drawing the text?
Since you are using MFC Feature Pack, just cast your button into a CMFCButton class. Then you can call CMFCButton::SetImage to add the image.