-
-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
update HTML data provider metadata #5700
Conversation
@@ -510,8 +510,7 @@ class CORE_EXPORT QgsRasterDataProvider : public QgsDataProvider, public QgsRast | |||
//! \note not available in Python bindings | |||
static QStringList cStringList2Q_( char **stringList ) SIP_SKIP; | |||
|
|||
static QString makeTableCell( const QString &value ); | |||
static QString makeTableCells( const QStringList &values ); | |||
static QString makeHtmlBulletList( const QStringList &values ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can this methods be private? Possibly even a generic QgsHtmlUtils
class would be nice to create the same kind of lists throughout QGIS.
Mainly it shouldn't be exposed by the raster data api.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, better! It's fixed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A lot better, thanks!
310fbbd
to
616da5b
Compare
src/core/qgshtmlutils.cpp
Outdated
{ | ||
QString s( QStringLiteral( "<ul>" ) ); | ||
|
||
for ( QStringList::const_iterator i = values.begin(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about a for ( const QString &value : values )
loop?
src/core/qgshtmlutils.cpp
Outdated
i != values.end(); | ||
++i ) | ||
{ | ||
s += QLatin1String( "<li>" ) + *i + QLatin1String( "</li>" ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If in doubt, use a template based approach QStringLiteral( "<li>%1</li>" ).arg( value );
src/core/qgshtmlutils.h
Outdated
* \ingroup coregit st | ||
* \class QgsHtmlUtils | ||
* \brief Class for HTML utilities. | ||
* \since QGIS 3.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this targetting 3.0 or 3.2?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's fixing bug https://issues.qgis.org/issues/17504 so 3.0, Is-it not possible?
BTW, I will fix the + * \ingroup coregit st
visible here L24
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wasn't sure, if it fixes a bug, 3.0 is the way to go 👍
88b15cf
to
06ea959
Compare
Failing test seems unrelated to the PR https://dash.orfeo-toolbox.org/viewTest.php?onlyfailed&buildid=299224 |
06ea959
to
4273ad2
Compare
Travis is happy again. Anything to else to fix? |
Can we merge this PR? Thanks |
Thanks @Gustry ! |
* update HTML data provider metadata for grass, gdal and ams * update HTML data provider metadata for WMS and WCS * move HTML bullet list to QgsHtmlUtils
Description
Bringing back the HTML metadata from the raster provider. (Pixel size, dimension, Origin etc ...)
No more the old
glossy
. I can still improve the CSS laterThis PR only updates the old HTML
Tickets:
Checklist
fixes #11111
in the commit message next to the description[FEATURE]
in the commit message[needs-docs]
in the commit message and containt sufficient information in the commit message to be documentedscripts/prepare-commit.sh
script before each commit