UML Designer supports drawing UML activity diagrams. Join and fork nodes are horizontal bars by default:
How can I make them vertical (flip them 90° or 270°)?
See the figure 12.95 at UML Superstructure v2.1.1:
I just figured out that UML Designer has an open feature request about this issue. So, currently...
How can I make them vertical (flip them 90° or 270°)?
... you can't.
Related
Recently, I tried to realize a semi transparent surface in Qt3D. I put this semi transparent surface in the scene graph in Qt3D together with many other entities that should be draw. However, I found that the drawing order of the surface is not fixed, which seriously affect the blending effect.
How can I know the drawing sequence of the entities in the scene graph in Qt3D? Also, how can I make sure that my semi transparent surface was drawn last?
Thank you.
What you are looking for is the class QSortPolicy. You can set the sorting policy there to back to front, to draw the transparent surface last. Although, according to the documentation, the drawing order depends on when the entities appear in the scene graph, when no sorting policy is present.
Other than that, I found a frame/scene graph in Qt3D that showcases a transparent object here: https://github.com/alpqr/q3dpostproc. It's written in QML but you should be able to transfer it to C++ without much work.
I'm developing a game with THREEjs and webvr-boilerplate. I'm struggling a bit with how to properly render a HUD (score, distance, powerups etc) that always stays at the top of the scene. I've tried to have a plane (with a texture that's brought in from a hidden canvas element) but positioning it in space proves difficult since I can't match the right depth.
Any clues please? :)
Well, you shouldn't have a classic HUD, VR doesn't work like that.
You're searching for something called diegetic or spatial UI - that is the scores and other icons are rendered as geometry in scene space in a fixed position or distance (this one is called spatial UI). For best results, draw the information on some game object mimicking real displays, for example a fuel gauge on the dashboard of a car or visible remaining bullets on a gun (this one is called diegetic UI).
Unity has made a nice page describing these concepts.
I created a performance statistics HUD specifically for WebVR & THREE.js Projects.
https://github.com/Sean-Bradley/StatsVR
While the default setup shows specific information, you can modify it to show custom graphics and other data.
And if you don't believe me, just check out the
StatVR video tutorial.
I am working on a Project in which I have to create an editor, which can create and transform ellipses. I understand all the necessary programming to do it with a GUI for the transformations, but it looks and feels better when all the Ellipses can be transformed by mouse. I know how to drag them, so that shouldn't be a problem, but for the transformation of the 2 radii and the rotation I have no clue.
An sketch of what I'm looking for:
If the grabbing points are visible or not doesn't matter. Do any of you have a knowledge of how to do this easily or if there already is code out there?
I didn't find anything on Google(may be my average search skills though).
Every Node in JavaFX has convenience methods to set transformations. So all you have to do is to register your desired input handlers aplly some transforms based on the mouse position.
ellipse.setRadiusY( radiusY );
ellipse.setRadiusX( radiusX );
ellipse.setRotate( angle );
See a full example.
I'm trying to apply readable labels to a D3 Streamgraph that is rendered using completely dynamic data - various different datasets that are evolving over time from live data and the controls offered to manipulate what is shown too. All this works well - the problem is how to clearly label the streams - short of using a legend.
The great variation of hues and luminance needed makes choosing readable styling for labels that float over the graph extremely tricky, particularly with the limited SVG styling available cross platform and that the labels will inevitably overlap on the background sometimes too. For instance black coloured labels 'work' but it's hard to read sometimes over the top of darker colours (which we really need to ensure a good range)...
Anyone done anything similar/addressed same challenge? I'm currently pondering using a legend instead.
A couple of ideas may help:
Add a background rectangle around the text with opacity set to 0.7 (the color being the same as the data series). This helps make the text pop. For the border of the rectangle, use d3js rgb.darker or rbg.brighter.
var pathStroke = d3.rgb( item.color ).darker(1.4).toString()
For preventing overlapping labels, I can think of two solutions - both hard. Use d3js Force Layout or write your own layout code. We ended up writing our own layout code for tooltips in d3-traits. See tooltips.js and layout.js.
d3.trait.layout.verticalAnchorLeftRight( foci, self.chartRect())
layout.js does have some general purpose and very flexible layout routines. It will layout rectangles within a bounding box avoiding overlap and determines if the labels need to be left or right justified. If the origins of the rects are toward the right edge of the bounding box, they are right justified.
As per My requirements i need to generate a histogram chart using cocoa framework and objective c.
If any one knows the solution please let me know ASAP.
Thanks,
Ravi
You could use Core Plot. It doesn't support histograms directly, but if you calculate the bins and counts yourself, a bar plot is pretty easy to set up. The framework handles drawing everything including the axes and labels. It works on Mac, iPhone, and iPad.
Depending on your needs you can use a custom UIView subclass and perform the drawing by hand (overwrite drawRect:) or add UIViews for every bar (making nice animations possible with few code, but will not be efficient if many bars are needed).
You can easily write your own CALayer using CoreAnimation.
You will just need some basic CALayers with their colors, borders and shadows to draw the bars and some CATextLayers to draw the text on the axis or below bars.
With some basic CA knowledge it will be easy and allow you to easily customize the graph with animations or effects..
I know this question is pretty old but i found a link that gives sample code for drawing histogram
http://www.keepedge.com/iphone_charts/histogram_chart.html
You can look at DSBarChart. It does exactly what you want.
http://www.cocoacontrols.com/platforms/ios/controls/dsbarchart