Windows build script will now save, and check, the last build commit and
skip building if there are no new commits since the last automatic build.
See #1917.
Matter came up WRT #1880. In reviewing, several other instances
were found where same file filter as a string literal was repreated.
This commit centralizes these file filters to one location. Filters
are declared `static const` to prevent accidental modification.
Also applied is a fix to #1881. QMessage at end of Import CSV is removed.
From upstream source, QHexEdit is intended to be a modular widget
for Qt5. (README @ https://github.com/Simsys/qhexedit2)
Add ability for platforms that already have QHexEdit installed to
build DB4S against installed (external to DB4S) QHexEdit library.
Current version of library available is consistent with version
contained in DB4S project `libs` folder.
(see https://repology.org/project/qhexedit2/versions)
Default of CMake flag FORCE_INTERNAL_QHEXEDIT is ON (enabled) so
as to minimize impact to current development workflow and other
platforms. Using flag is left as an option to package managers.
Problem identified in Github Issue #1910.
Update to CMake had policy warning of AUTOMOC usage.
See https://cmake.org/cmake/help/latest/policy/CMP0071.html
Commit adds instructions to silence the warning.
Affect of AUTOMOC behaviour with 'new' needs further study.
Saving cannot be done in the class destructor, since it seems that the
sizes have already change in that moment. Now they are saved under request
of the Main Window at the same time when the Main Window state is saved.
See issue #1889.
Whenever the splitters between the SQL editor, the table result and the
last execution results panes are moved, the sizes are saved to memory (for
performance) so the next SQL tab to be opened restores them. When an area
is destroyed the last saved settings are saved to disk, so they are ready
for the next execution without much impact in disk utilisation.
Issue #1889
When opening a project file the following exception is raised in
src/sqlitedb.h:208
terminate called after throwing an instance of 'std::out_of_range'
what(): map::at
This is related to 64a596a887
Saving and restoring of quote and separator characters did not work as
expected in the Import CSV dialog since the last commits. A missing
"else" made us try to save the string "Other" as the quote character
when a custom quote character was selected. Also the translation from
and to the saved format on disk had its problems.
See issue #1860.
This adds a new dialog, accessible from the Remote tab in the Preferences
Dialog, which allows the user to configure the proxy to use for all
network connections.
The new default is to use the system-wide proxy settings.
See issue #979.
The dbhub.io server provides us the last modified date of the database
when cloning it. Because we send the last modified date back to the
server when trying to push a database, it makes sense to initially set
the last modified date of the local file to the date provided by the
server.
See issue https://github.com/sqlitebrowser/dbhub.io/issues/101.
This adds support for more characters as field separator and for quoting
in the CSV import. Before this we only supported ASCII characters, with
this we support all characters which when UTF-8 encoded require up to
16 bits.
See issue #1860.
Problem traced to QFile::exist() producing message when passed an empty QString.
Fix is to test QString length before any QFile::exist() usage with that string.
Compile with ALL_WARNINGS using GCC 8.2.1.
Encountered approximately dozen warnings with this pattern:
[path to sqlitebrowser root]/src/[somesourcefile]:line:cursor: warning: declaration
of ‘data’ shadows a member of ‘ClassName’ [-Wshadow]
OtherDataType data = ....line of code at line given above...
^~~~
In file included from /usr/include/qt5/QtWidgets/qdialog.h:44,
from /usr/include/qt5/QtWidgets/QDialog:1,
...other sources in project
/usr/include/qt5/QtWidgets/qwidget.h:733:18: note: shadowed declaration is here
QWidgetData *data;
^~~~
It appears there is a variable named 'data' within Qt global scope. Using 'data`
as a variable name, even one limited in scope to small lamda expressions, causes
compiler some grief.
Commit resolves the warnings in affected files. No problems apparent during execution.
Requires CSV stress-testing.
Include path used for QHexEdit in EditDialog.cpp is "implementation specific"
to how DB4S uses the QHexEdit library. Change is to make usage of library
more generic.
It turned out that on some platforms we still aim to support the stdlib
had not yet implemented std::regex. For this reason we want to avoid
using it for now.
In the particular use cases here it was also not the best solution. It
was faster to write using a regular expression instead of a hand coded
loop but clearly a simple loop should be more efficient here.
See issue #1873.
Respect the suggested order of the licences as provided by the dbhub.io
server instead of sorting them alphabetically by their internal key.
Also remove the hard-coded "Unspecified" licence option because the
dbhub.io server provided its own "No licence specified" option.
This adds a built-in, default certificate which enables read-only access
to dbhub.io. This should make it easier to try out the remote features.
When trying to open the Push Database dialog, a message with more
details and all required links is displayed.
We started to use Niels Lohmann's JSON library instead of the one
included in Qt for the Export JSON dialog a while ago because Qt's
implementation showed some problems. To avoid any similar issues and
because Niels' library has a much nicer API, this commit migrates all
our code to his library.
In the Browse Data tab updating a row after having updated its primary
key or part of it before was broken for multi-column primary keys. When
updating the value of a primary key column and then updating any part of
the row afterwards, we were still using the old value until the view was
refreshed. With this commit it is possible to immediately update the
row using the updated primary key values.
See issue #1834.
This improves the performance for loading row data with my setup by
about 10%. Incidentally, the conversion from Qt to STL containers
reduced the performance by about the same number.
This adds another primitive benchmark tool which in this case helps
measuring the time required to load all remaining rows from the selected
table. When activated using the LOAD_DATA_BENCHMARK define, it opens a
message box after loading of all rows using the fetch-all-data button in
the Plot Dock is clicked.
produced. Messages would take the form:
[SQLB root]/src/sql/sqlitetypes.cpp:465:79: warning: declaration of ‘fields’ shadows a member of ‘sqlb::Table’ [-Wshadow]
and reference
[SQLB root]/src/sql/sqlitetypes.h:310:17: note: shadowed declaration is here
FieldVector fields;
All incidents isolated to [SQLDB root]/src/sql/sqlitetypes.{h,cpp}.
Change renames local variables to silence warnings.
no errors after execution w/ gcc/clang builds on Linux.
When a PRAGMA query did not return any value (most notably the PRAGMA
foreign_key_check after editing a table using the Edit Table dialog), we
used to print an error message to the console. There were no further
side effects but the message could be irritating. This extra error
message is removed by this commit.
See issue #1868.