Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UAVO: Add description element to fields, add tooltips in UAVO Browser #60

Merged
merged 4 commits into from
Nov 29, 2015

Conversation

tracernz
Copy link
Member

I was going to sleep but then I kept thinking about this :-P. Fixes #41.
UAVOs can now have an optional description element inside each field. This field is used in the GCS object browser to display tooltips on each UAVO field. No field descriptions are actually defined in this PR (an issue will be created once merged). To test you will need to add a description to one or more fields, e.g. in https://github.com/d-ronin/dronin/blob/next/shared/uavobjectdefinition/actuatorsettings.xml#L4:

        <field name="TimerUpdateFreq" units="Hz" type="uint16" elements="6" defaultvalue="50">
            <description>How often your spinny things get a fresh command.</description>
        </field>

*/
QString UAVObjectGeneratorGCS::escape_raw_string(QString raw)
{
return raw.replace("\\", "\\\\").replace("\"", "\\\"").simplified();
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The QString::simplified function replaces all whitespace chars with a single space, and gobbles consecutive whitespace into a single space.

@tracernz tracernz force-pushed the uavo-howtomakefly branch 4 times, most recently from 3f8d41a to 3bbeab4 Compare November 27, 2015 06:04
@mlyle
Copy link
Member

mlyle commented Nov 27, 2015

I've read but not tested this. Probably at least a couple token desc's would be nice to merge as part of this PR.

Also need to verify that it doesn't break the python API

@tracernz
Copy link
Member Author

Rebased to next.

@mlyle
Copy link
Member

mlyle commented Nov 29, 2015

jenkins, test this please

@mlyle
Copy link
Member

mlyle commented Nov 29, 2015

You or I should do the python stuff as part of this PR.

And tooltips in GCS UAVOBrowser
Fixes d-ronin#41
It already was anyway in addition to our attempted wrapping control (which just resulted in unnecessary wraps being inserted).
ActuatorSettings
AttitudeSettings
HomeLocation
TaskInfo
@tracernz
Copy link
Member Author

Added python code to parse descriptions, rebased on next.

@mlyle
Copy link
Member

mlyle commented Nov 29, 2015

pending jenkins

mlyle added a commit that referenced this pull request Nov 29, 2015
UAVO: Add description element to fields, add tooltips in UAVO Browser
@mlyle mlyle merged commit efd8df7 into d-ronin:next Nov 29, 2015
@tracernz tracernz deleted the uavo-howtomakefly branch November 30, 2015 02:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants