Possible to view class hierarchy with labels? - graphdb

I work in a framework, like OBO, where we use opaque IRIs and rely on labels to view terms. The class hierarchy shows IRIs, and so is unusable for us as is. Is there a way to configure a label (or labels) for viewing that visualization.
I am currently using GraphDB Free while prototyping some new work.

Related

Programmatically Draw With Measurement Widget

I'm using an ArcGIS scene with an AreaMeasurement3D widget to allow users to draw a region to provides some parameters for a db query. I would also like them to be able to type in coordinates and have the widget produce a measurement for them. I see there's a newMeasurement method available but it doesn't seem to support this. Is there some other way to programmatically draw a region with this widget?
It's not clear to me whether you want to reuse the AreaMeasurement3D widget to retrieve the actual measurements or use it to visualize the area. At this point the measurement tools do not support this.
I would suggest to use geometryEngine.geodesicArea() or geometryEngine.planarArea() to calculate a measurement from given coordinates.
Using a GraphicsLayer you could then visualize the area as shown in the Add Graphics sample.

Imagemap usage in qml

Is there any way to build an image map with qml (qt quick) components directly without importing html code?And I want to it's coordinates be same as html imagemap's coordinates(I dont want to recalculate my image map coords).
and
my shape is rectangular.tnx
No, there is no way. MouseAreas are always rectangular.
You would need to provide a some kind of collision detection function, to check whether your click happened inside of your object, described by the coordinates.
For this you can implement any of the algorithmns out there, in a way, that it supports your coordinate format. The right choice depends on the characteristics of your objects, like:
Is it a circle?
Is it a regular shape?
Is it convex?
Is it concave?
There are many good pages on collision detection, though a performant implementation might be tricky - especially in QtQuicks JS, so you probably want to do it in C++.
Another shot you might take, is dropping your coordinates, and produce masks that can be used with the solution provided here: https://stackoverflow.com/a/38177820/2056452 (coming from an official example)

Stack Editors and Views

I'm using E4, where all views and editors are parts and can be stacked on top of each other. However, I'm using the compatibility layer (aka the lesser evil). Still, stacking is possible, I can manually put views on top of editors and vice versa.
The question is now: How to configure the perspective, so that editors and views are stacked on default?
I tried to implement the IPerspectiveFactory:
final IFolderLayout mainFolder = layout.createFolder("main", IPageLayout.RIGHT, 0.95f, layout.getEditorArea()); //$NON-NLS-1$
mainFolder.addPlaceholder("*"); //$NON-NLS-1$
But there is no constant IPageLayout.STACK, and the above snippet does not work either.
I tried to configure the extension point, but could not figure out how to add placeholders. Also, it seems it does not work with the intro view.
So how do I stack views and editors programmatically?

Is there any way to draw a line diagram using array of x, y co-ordinates in appcelerator?

If I select one of these co-ordinates, I want to highlight that point on the diagram (by a circle or whatever shape possible). Also I would like to save it later on.
I'm not sure if Appcelerator is flexible enough to do all these things (My search didn't yield much apart from here, this only supports Android), If not I'll have to generate this diagram in my webservice and pull it back on UI once there is an update in the co-ordinate array.
I've used Chartist inside a webview and it worked great. It produces a SVG graph instead of a canvas object which performs better.
If you want to use hyperloop you can use Ti.AndroidCharts

Simple Drawing App Design -- Hillegass Book, Ch. 18

I am working through Aaron Hillegass' Cocoa Programming for Mac OS X and am doing the challenge for Chapter 18. Basically, the challenge is to write an app that can draw ovals using your mouse, and then additionally, add saving/loading and undo support. I'm trying to think of a good class design for this app that follows MVC. Here's what I had in mind:
Have a NSView-subclass that represents an oval (say JBOval) that I can use to easily draw an oval.
Have a main view (JBDrawingView) that holds JBOvals and draws them.
The thing is that I wasn't sure how to add archiving. Should I archive each JBOval? I think this would work, but archiving an NSView doesn't seem very efficient. Any ideas on a better class design?
Thanks.
Have a NSView-subclass that represents an oval (say JBOval) that I can use to easily draw an oval.
That doesn't sound very MVC. “JBOval” sounds like a model class to me.
Have a main view (JBDrawingView) that holds JBOvals and draws them.
I do like this part.
My suggestion is to have each model object (JBOval, etc.) able to create a Bézier path representing itself. The JBDrawingView (and you should come up with a better name for that, as all views draw by definition) should ask each model object for its Bézier path, fill settings, and stroke settings, and draw the object accordingly.
This keeps the knowledge of how to draw (the path, line width, colors, etc.) in the various shape classes where they belong, while also keeping the actual drawing code in the view layer where it belongs.
The answer to where to put archiving code should be intuitively obvious from this point.
Having a whole NSView for each oval seems rather heavyweight to me. I would descend them from NSObject instead and just have them draw to the current view.
They could also know how to archive themselves, although at that point you'd probably want to think about pulling them out of the view and thinking of them more as part of your model.
Your JBOval views would each be responsible for drawing themselves (basically drawing an oval path and filling it, within their bounds), but JBDrawingView would be responsible for mousing and dragging (and thereby sizing and positioning the JBOvals, which would be its subviews). The drawingView would do no drawing itself.
So far as archiving, you could either have a model class to represent each oval (such as its bounding rectangle, or any other dimensions you choose to represent each oval with). You could archive and unarchive these models to recreate your views.
Finally, I use the JB prefix too, so … :P at you.