Commit Graph

1200 Commits

Author SHA1 Message Date
Chuong Vu 74fd0793e3 Remove default NULL text for NULL value fields
See issue #163
2015-02-15 01:16:59 +01:00
Chuong Vu eda00dcd81 Add setting to allow user to change the background color of NULL value fields
See issue #163
2015-02-15 01:16:59 +01:00
Samir Aguiar 9fa174f8f9 unittests: Add PreferencesDialog files
The sqlitetablemodel will need to access the color
setting for null fields. This breaks the tests if
the PreferencesDialog files are not linked to the
test executable.
2015-02-15 01:14:35 +01:00
Chuong Vu f3cc98317a Add NULL to the SQL Preferences tab 2015-02-15 01:13:36 +01:00
Samir Aguiar 4fee089d4d Fix QStrings that had placeholders for queries
When replacing placeholders, QString::arg() looks for
the sequence %n (where n is a number between 1 and 99).
As it turns out this sequence can also appear in SQL
queries and so they were being mistakenly replaced.

See issue #203.
2015-02-14 19:28:47 +01:00
Samir Aguiar a5d6e6df7a preferencesdialog: Add country flag to language combo box
See issue #182.
2015-02-13 23:49:33 +01:00
Samir Aguiar 774e428b30 preferencesdialog: Suffix to identify system and default languages
Also, move the selected language to the top of the language
combo box.
2015-02-13 23:44:55 +01:00
Samir Aguiar 8a4838057d preferencesdialog: Remove unnecessary sort model
Turns out that the use of a QSortFilterProxyModel wasn't
necessary, as it's possible to sort the QCombobox using
its model directly.
2015-02-13 23:44:55 +01:00
Justin Clift 9764e81441 Updated currentrelease to 3.5.1
Oops, should have done this already. ;)
2015-02-13 19:37:49 +00:00
Martin Kleusberg 848b16f03e Set menu roles manually where possible
Qt tries to determine the role of a menu item based on its text. If the
text is "Preferences" it guesses that that menu item opens the
preferences dialog. On MacOS X this means the menu item is moved from
the View menu to the application menu. However, for translations this
doesn't seem to work, so this commit sets the menu roles manually. At
least that's the idea - no idea if it works.

See issue #200.
2015-02-11 18:53:21 +01:00
Justin Clift 027ba81d99 Added release date line for 3.5.1 2015-02-08 15:20:39 +00:00
Peinthor Rene 3b992e7337 executesql: use a different open sql file icon
The current one always looks to me as if the button is disabled.
2015-02-08 11:12:24 +01:00
Justin Clift 140c8d9805 Merge pull request #189 from samir-aguiar/master
qmake: Copy generated translations files into app bundle
2015-02-06 21:04:56 +00:00
Justin Clift 103a9a27c9 Merge pull request #198 from samir-aguiar/ui-fix
preferencesdialog: Restore ability to change default location
2015-02-06 20:34:31 +00:00
Samir Aguiar 0b6f0f45e0 preferencesdialog: Restore ability to change default location
Commit ae03113 broke the UI: the signal triggered when pressing
the button to change the default location and the tab order
had been lost.

See issue #197.
2015-02-06 19:56:16 +01:00
Martin Kleusberg 03b4ef9d1f Further improve 408fbcf8b4 2015-02-06 14:36:53 +01:00
Martin Kleusberg 408fbcf8b4 Use same data type as SQLite for primary keys
This improves commit c20c58595a to
definitely make sure the primary key values are stored and handled
correctly by simply using the same data type as SQLite itself does.
2015-02-06 14:08:59 +01:00
Martin Kleusberg 4fa0576853 Support tables with empty table names
Apparently SQLite supports empty table names for whatever reason. This
commit patches SQLiteBrowser to support databases with a table with an
empty name. I haven't removed the check for an empty table name in the
Create/Edit table dialog though because you probably really shouldn't
create such a table.

See issue #194.
2015-02-06 13:30:30 +01:00
Peinthor Rene 8d55fd5c48 cvsparse: used wrong var for last row check 2015-02-05 15:58:42 +01:00
Martin Kleusberg c20c58595a Support 64bit primary keys
Primary keys in SQLite are 64bit in size. We, however, used the int
datatype which often is 32bit only. Also the conversion from QString and
other Qt datatypes to numbers was done by the toInt() method which fails
on these large numbers. These issues are fixed by this commit, adding
support for databases with big primary key values.

See issue #172.
2015-02-04 17:55:43 +01:00
Martin Kleusberg f63b11925d cipher: Fix attaching unencrypted DB if main is encrypted and vice-versa
When attaching another database, SQLCipher assumes that it shares
passphrase and salt with the main database. Usually this isn't the case,
though. With this commit SQLiteBrowser tries to open the database to attach
before actually attaching it and asks for encryption details if needed.

This allows the user to attach unencrypted databases to an encrypted
master database and vice-versa. Note though, that attaching an encrypted
database with a non-default (i.e. <> 1024) cipher page size doesn't seem
to work - this however, is apparently a SQLCipher limitation.

See issue #174.
2015-02-04 17:16:13 +01:00
Justin Clift 0457b7803e Added 3.5.0 release to the README.md Releases line 2015-01-31 18:56:37 +01:00
Justin Clift 727f983c17 Updated currentrelease to 3.5.0 2015-01-31 18:54:40 +01:00
Peinthor Rene d0f3de3927 addrecord: a small fix that should make add record a bit more robust 2015-01-30 19:47:36 +01:00
Samir Aguiar 25eb83b1a1 qmake: Copy generated translations files into app bundle
The translations were not being added to the bundle when
deploying the Mac app and thus no language other than
English could be loaded.
2015-01-27 23:03:30 +01:00
Peinthor Rene 78df7275fe windowsupdatecheck: Fix a small memory leak 2015-01-27 22:14:20 +01:00
Martin Kleusberg d6b887d4f0 Merge pull request #187 from samir-aguiar/master
Add language combobox to the Preferences menu
2015-01-25 20:38:37 +01:00
Samir Aguiar ce8f49d530 localization: Use path relative to the application executable
This allows the languages to be loaded when the user is
running the app from another directory (e.g. when the app
is run from an exported path).
2015-01-21 23:06:03 +01:00
Samir Aguiar ae031137b3 preferencesdialog: Move default location option to General tab 2015-01-21 23:06:02 +01:00
Samir Aguiar eb1a32ef24 localization: Rename Chinese translation file to match locale
This allows the file to be included in the language box
(Qt wasn't recognizing the "cn" suffix as a valid locale).
2015-01-21 23:06:02 +01:00
Samir Aguiar 6d6544043d preferencesdialog: New combobox to change application language
The behavior remains basically as before: when first launched
the application will try to load a translation for the user's
locale, and if one cannot be found it defaults to English.
The difference is that now this is remembered so that upon
further launches the program will go straight to the matching
locale.

See issue #182.
2015-01-21 23:06:02 +01:00
Justin Clift 823e51a917 Added FreeBSD pkg install info. Closes #180. 2015-01-19 16:39:30 +00:00
Martin Kleusberg a4d41be2a1 Merge pull request #185 from pinotree/tests-fix-qcoreapp
tests: fix QCoreApplication parameters
2015-01-17 14:32:17 +01:00
Pino Toscano afaf2ca73c tests: fix QCoreApplication parameters
The argument count (first parameter) is a reference, and thus must be
kept alive for the whole lifetime of the QCoreApplication instance,
as also the Qt apidocs say.

Also properly create a "string array" for the actual args, instead
of badly casting a string to that.

This fixes sporadic crashes in this test.
2015-01-17 13:06:22 +01:00
Martin Kleusberg a6bd96774a grammar: Support conflict clause in primary key constraint
Support conflict clauses (like ON CONFLICT REPLACE) inside a PRIMARY KEY
column constraint.

See https://www.sqlite.org/syntax/column-constraint.html
2015-01-16 23:35:55 +01:00
Peinthor Rene c6f585e9c4 grammar: also allow ID tokens as default argument 2015-01-12 17:29:18 +01:00
Martin Kleusberg 414f27e50a Merge pull request #181 from samir-aguiar/master
qmake: Add compatibility with shadow build
2015-01-08 22:54:55 +01:00
Samir Aguiar db7fdc2a04 qmake: Add compatibility with shadow build
See issue #175.
2015-01-07 19:15:35 +01:00
Justin Clift a1c2108913 Added link to lbartoletti text 2015-01-06 22:30:59 +00:00
Justin Clift 48b70c3d63 Added FreeBSD port info to the FreeBSD section
Thanks @lbartoletti :)
2015-01-06 22:29:03 +00:00
Martin Kleusberg a090875575 tests: Add test for grammar fix in 1ea67c33d2 2015-01-06 14:12:08 +01:00
Martin Kleusberg 1ea67c33d2 grammar: Fix string literals in CHECK expressions (and maybe other places)
Fix parsing of table definitions like this one where there is a complex
check constraint using string literals:
CREATE TABLE "a" (
    `b` TEXT CHECK(`b`='A' or `b`='B')
);
The grammar parser would fail to parse this statement correctly prior to
this fix.

See issue #179.
2015-01-06 14:11:28 +01:00
Martin Kleusberg 0f4ac7e89c index: Support creating indices without sorting
See issue #176.
2014-12-26 16:20:20 +01:00
Peinthor Rene e01307aa73 Merge pull request #168 from justinclift/os2v2
Added icon for IBM OS/2
2014-12-08 11:45:21 +01:00
Peinthor Rene 46cfc99031 browsetab: change go to begin/end button text so its more obvious begin and end is meant 2014-12-08 11:43:08 +01:00
Peinthor Rene c868ff1f12 Merge branch 'yunfzhan-master' 2014-12-08 11:38:53 +01:00
Peinthor Rene 9ca6c5f3bb Merge branch 'master' of git://github.com/yunfzhan/sqlitebrowser into yunfzhan-master 2014-12-08 11:36:49 +01:00
Elbert Pol 5879553c5f Added icon for IBM OS/2 2014-12-05 09:20:29 +00:00
yunfzhan 71cf0531fe Add two buttons to navigate to the head and the tail. 2014-12-02 18:23:52 -08:00
Martin Kleusberg ce41627984 Don't use deprecated pragmas
Don't call the empty_result_callback and show_datatypes pragmas when
opening or creating a database file. The first one is marked as
deprecated in the documentation [1] and the latter one doesn't appear
there at all anymore but was removed in February 2004(!) [2].

[1] https://www.sqlite.org/pragma.html#pragma_empty_result_callbacks
[2] https://www.mail-archive.com/sqlite-users@sqlite.org/msg01252.html
2014-12-02 21:15:00 +01:00