Archived OpenModelica forums. Posting is disabled.

Alternative forums include GitHub discussions or StackOverflow (make sure to read the Stack Overflow rules; you need to have well-formed questions)


Forgot password? | Forgot username? | Register

Documentation item in the context menu in OMEdit

Documentation item in the context menu in OMEdit

I learned the modelica standard library with OMEdit 13. There you could right click on a symbol in a library or model could open the related documentation from the context menu. This helped me a lot to read the documentation. 

Now this feature is missing in OMEdit 14. One has to open the class, in order to see the documentation. This ends up with more opened classes, as one like to have.

Are there any reasons to disable the documentation item in the context menu or is it just a regression?

Ulrich

Re: Documentation item in the context menu in OMEdit

It has been removed to make the "prefferedView" annotation work properly. Also previously you can open the documentation of any model regardless of what you have opened in the modeling view. Now the two views are synced. If you navigate to some class in the documentation the modeling view will also open the same class. So it doesn't make sense to have documentation in the context menu.

Adeel.

Re: Documentation item in the context menu in OMEdit

I do prefer the previously available options. I often had the situation, to put parameters in for a part in my model, but did not know what to put in. Previously it was possible to have the model open and see the documentation of the part in question and open at the same time the parameter menu of that part. In this way it was easily possible to copy sample values given in the documentation or just look up an explanation while the parameter menu is still open.

Now this is not possible anymore. You need to learn each parameter and remember it. Then switch to another window and open the parameter menu in order to fill in the parameters. Having the documentation available at time of filling in, is much more convenient.

The same holds for looking up the modelica grammar. I could see an example of the documentation side by side with my own code. This is what I am missing now.

I do understand that this may not be important once you have learned everything. However, this feature was very helpful for me as a beginner in modelica.

Ulrich

Edited by: ulrich1a - Oct-30-19 18:06:53

Re: Documentation item in the context menu in OMEdit

Hi,

I would like to second ulrich1a feedback. For me the new behavior of OM 1.14 which synchronizes the views is a regression. It is often the case that I need to the read the doc of component when developping the upper level model which uses that component.

Is there already a bug report where we could elaborate this?

Best,
Pierre

Re: Documentation item in the context menu in OMEdit

My original requirement, which I guess caused what you (rightfully) consider a regression, was that I found it totally weird, and quite annoying, that every time I selected a new class on the Libraries browser or by selecting a different tab, the documentation "lagged behind" and I needed to resync it separately.

However, I think there is a way to second everybody's requirement. We shouldn't make the documentation windows always in synch with the main tabbed windows where the model code or diagram is shown. Rather, we should make sure that every time we


  • select a new model in the libraries window

  • select a new tab

  • right-click on an instance of a model in a diagram and select "Show documentation"


the diagram view is updated accordingly.

Adeel, is this easily implemented?

Edited by: casella - Jan-17-20 13:08:22

Re: Documentation item in the context menu in OMEdit

As I understand now we can generalized the actions in 2 ways. The actions on the Diagram view and the actions on the Documentation view. Whenever the Diagram view changes we update the Documentation View to it but when the Documentation View changes we don't update the Diagram View.

@casella note that this will again open the issue that you originally had i.e., when the Documentation view is not in sync with Diagram view and you update the documentation of the class. That was the original issue for you that you don't know for which model you are updating the documentation since they both are not synced.

Another solution which is probably more effective but requires more time to implement is that we make the Documentation view completely independent (as it was previously) but also make it just a read-only view. For editing we add a new view inside the Diagram view, so now we have have icon, diagram and text and instead we should have icon, diagram, text and info. Clicking on info opens the documentation in the diagram view and there you can also edit it. Clicking on any link inside the documentation will switch to a new model.

Adeel.

Re: Documentation item in the context menu in OMEdit

Any solution that fulfills my three requirements is good for me current/smile

Re: Documentation item in the context menu in OMEdit

Would you mind opening a ticket on https://github.com/OpenModelica/OpenMod … new/choose with your requirements? This forum is only for discussion and helping people.

Thanks!

There is 1 guest and 0 other users also viewing this topic
You are here: