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

use new QgsHelp where possible instead of builtin context help #4023

Closed
wants to merge 1 commit into from
Closed

use new QgsHelp where possible instead of builtin context help #4023

wants to merge 1 commit into from

Conversation

alexbruy
Copy link
Contributor

No description provided.

@@ -134,7 +134,7 @@ class QgsOracleSourceSelect : public QDialog, private Ui::QgsDbSourceSelectBase
//!Sets a new regular expression to the model
void setSearchExpression( const QString& regexp );

void on_buttonBox_helpRequested() { QgsContextHelp::run( metaObject()->className() ); }
void on_buttonBox_helpRequested() { QgsHelp::openHelp( QStringLiteral( "working_with_vector/supported_data.html#id2" ) ); }
Copy link
Member

Choose a reason for hiding this comment

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

I wonder if we should make more verbose anchors in the docs (although this particular one here could also be simply dropped) @DelazJ @yjacolin

Copy link
Contributor

@DelazJ DelazJ Jan 19, 2017

Choose a reason for hiding this comment

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

To be honest, I still do not understand the way things are supposed to be implemented (sorry!). Will build this branch tonight :)
About the link, yes we should use more verbose link, because, if a new section or new hyperlink is inserted above in this chapter, the #id2 could not point to the same section

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Completely agree, it would be nice to have more verbose anchors.

Copy link
Member

@m-kuhn m-kuhn Jan 19, 2017

Choose a reason for hiding this comment

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

When the help button is clicked, the browser will be opened with the url http://docs.qgis.org/2.14/en/docs/user_manual/working_with_vector/supported_data.html#id2

But you can also download and unpack the docs to e.g. /usr/share/doc/qgis/user_manual and configure this as an additional prefix with higher priority to have a local (preferred) doc.

@alexbruy correct me if I'm wrong please.

Copy link
Contributor

@DelazJ DelazJ Jan 19, 2017

Choose a reason for hiding this comment

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

Ok this is what I understood. But what changes does this require from the way we currently write docs? What should I be careful to not change the next time I update the doc (note that this chapter particularly is supposed to be reorganized in the future - qgis/QGIS-Documentation#1088)?

When the help button is clicked, the browser will be opened with the url http://docs.qgis.org/2.14/en/docs/user_manual/working_with_vector/supported_data.html#id2

shouldn't it rather be this one http://docs.qgis.org/2.14/en/docs/user_manual/working_with_vector/supported_data.html#oracle-spatial-layers (the permanent link and not the relative one - which is btw #id25 and not #id2)?

Copy link
Member

Choose a reason for hiding this comment

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

I think the main question to the doc is how to maintain a stable URI-schema (which is basically to be treated as an API).

  • Either the current addresses will remain stable.
  • Or there needs to be a mapping of stable addresses to resources (redirect mapping on the server)

What would be also nice is a travis check for dead links. Maybe have somewhere a list online (generated from QGIS master builds) with links which are in use. And join a second list generated from doc master builds. Where there is no matching doc, show it in red.
It's quite hard to get this right because doc and code are moving targets and there might be pull requests and stable releases involved.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

as @m-kuhn already said, this does not affect way we use to write docs. If you change something in the documentation, e.g. anchor name or move some section to another place you will need to update corresponding link in the code too. But I agree with Matthias here, that such changes should not be too frequent, at least within single version like 3.x, 4.x and so on

@m-kuhn
Copy link
Member

m-kuhn commented Jan 19, 2017

Nice @alexbruy , thanks for pushing this topic!!

@DelazJ
Copy link
Contributor

DelazJ commented Jan 19, 2017

Thanks @alexbruy for your work

@DelazJ
Copy link
Contributor

DelazJ commented Jan 19, 2017

I may be late in the organisation (if so, sorry! but it's also because I am not familiar with the vocabulary you used when creating the infrastructure) but is that intended to have a single file listing openhelp button and corresponding link/page? A kind of mapping between help buttons and doc section so that we have a single place to change links if ever?

@m-kuhn
Copy link
Member

m-kuhn commented Jan 19, 2017

For flexibility I would do a mapping (if there is one) on the server and not in the app.

@alexbruy
Copy link
Contributor Author

Manually merged

@alexbruy alexbruy closed this Jan 23, 2017
@alexbruy alexbruy deleted the docs-as-help branch January 23, 2017 08:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants