User configured context-menu

Would you like to see new features in Wandora?

User configured context-menu

Postby mordenkainen » Thu Mar 05, 2015 11:28 pm

Purpose: let user write custom operations for topics in TMQL, store them in a map, apply them fast for selected item.

How I'm using TMQL now.
I start with some preparations. Create Selected content class to store selected items, create Query content class with query occurrence type to store prepared
When I want to apply one of my queries I perform following steps:

1. Select target topics
2. Add them to the Selected class
3. Copy occurrence from desired query
4. Run Ctrl-F
5. Paste query inside the form
6. Run query
7. Remove all instances from the Selected class

What I'm seeking for

Built-in single player association to mark selected items. Every time user (de)selects topic(s) the associations is added (removed) to them.
Built-in class for storing queries. Its content should be a valid query.
Built-in class for storing user menu items. Menu item must have a display name and association with a query that determines its availability. The query is supposed to check if players in the selected association fit the menu item purpose, to show different menu items depending on context. Menu item is shown only If the query returns non-null value. Menu item may have any number of queries that would be run on activation. They stored as triple association between menu item, query exemplar, order of execution (any type allowing sorting).

As a result user would be able to select target topics and perform queried action by single click in the menu. There may be some common used actions included in the base map. As it already has predefined Wandora language list. And user may add anything he need to the topic map.

Optional features
Menu items that contains submenus.
Built-in class to store query run report (outputed tuples). To allow materialize query result in a permanent topic for further reviewing. All outputed tuples becomes associations typed with query that produced them.
Posts: 24
Joined: Fri Feb 13, 2015 5:11 pm

Re: User configured context-menu

Postby akivela » Fri Mar 06, 2015 5:38 pm


Interesting proposition. Thank you.

Let me suggest another solution that probably covers your idea but is much simpler and faster to implement.

What if Wandora user could store TMQL scripts into occurrences and execute these occurrence-stored TMQL scripts in a context-aware way. The user could place the TMQL scripts where they are used. And TMQL scripts are stored along the topic map. No need for external storage.

This solution would be similar to existing solution where Wandora can run occurrence-stored Processing and R language scripts. Also, this kind of solution would support my view of how I want to expand the role of occurrences in Wandora.

Kind Regards,
Site Admin
Posts: 257
Joined: Tue Sep 18, 2007 10:20 am
Location: Helsinki, Finland

Re: User configured context-menu

Postby akivela » Tue Mar 10, 2015 12:05 pm

Wandora's source code repository at Github contains a commit that adds Wandora the Run occurrence as TMQL feature. ... bec71d5b7a

The feature is still experimental and may change before release but the principle stays. Now the user can right click any occurrence and choose menu item Run occurrence > Run as TMQL. Wandora assumes the occurrence text is TMQL script and tries to execute it. Wandora views TMQL results in a dialog window with a topic table.

Kind Regards,
Aki / Wandora Team
Site Admin
Posts: 257
Joined: Tue Sep 18, 2007 10:20 am
Location: Helsinki, Finland

Return to Feature requests

Who is online

Users browsing this forum: No registered users and 1 guest