Commit Graph

2765 Commits

Author SHA1 Message Date
Justin Clift
56e6adaf3a Homebrew seems to have removed all support for formula options 2019-02-03 01:10:20 +11:00
Brook Milligan
21d8800ce6 CMake installation on macOS should also copy the icon & desktop files
Should address #1723
2019-01-31 17:08:14 +11:00
mgrojo
8162c96c15 Double click a column for selecting it
Since the mouse release triggers the sorting, we were unable to select
only one column. Connecting the double click over the header to a column
selection, we are able to select that column. However, we cannot select
one column without sorting by it, since the sorting is triggered before,
on the first mouse click.

See issue #1717
2019-01-26 21:11:49 +01:00
mgrojo
03e75af3f1 Rectify the sort indicator after multiple column selection
When more than one column is selected we abort the sorting, but Qt has
already assigned the sort indicator to the last selected column, so we
have to restore the saved settings to fix the sort indicator column.

See issue #1717
2019-01-26 20:51:02 +01:00
mgrojo
e22966ec23 Fix override warning in selectAll
This change fixes a cmpile warning on Mac OS: (10.12.6) + Clang

warning: 'selectAll' overrides a member function but is not marked
'override'

Fixes #1718
2019-01-24 23:20:20 +01:00
Tien Do
60c6bad895 Building with CMake on macOS (#1644) 2019-01-24 23:26:40 +11:00
Justin Clift
1380976f5f Merge pull request #1719 from tiendq/cmake-find-qscintilla
Find correct QScintilla package
2019-01-24 23:15:01 +11:00
Tien Do
4f939285fc refactor: find correct QScintilla package 2019-01-24 16:06:37 +07:00
Karim ElDeeb
98c9b3ba98 Fix shortcut items in the MSI installer
See issue #1713.
2019-01-20 01:52:39 +02:00
mgrojo
a14939913b New action "Save All"
New action "Save All" for saving all the files currently opened by the
application: DB file, SQL files and project file. Can be activated through
shortcut (Ctrl+Shift+S) and File menu.

Icon composed from package.png and database_save.png.

See issues #871 and #1706
2019-01-18 23:35:27 +01:00
mgrojo
f08cdb19b8 Ask user about saving any modified data in SQL tabs
User is asked once for saving modified SQL tabs not attached to a file to
the current project file (or to a new project file, when there isn't any
yet).

For each tab linked to a file, the user is asked to save the changes to the
file.

The asking is performed when the tab is closed, or when the application
is closing.

The modified attribute of the editor is set to false when the data is
saved or has just been loaded in the editor.

See issues #1386 and #1706
2019-01-18 00:11:43 +01:00
Martin Kleusberg
fbef621e5a Fix executing selection only in Execute SQL tab
When executing only a part of a query by selecting the start of it in
the Execute SQL tab, SQLite would execute it until the next semicolon,
even when the selection does not go as far. This commit changes this
back to the old behaviour to only ever execute exactly the selected part
of a query.

See issue #1708.
2019-01-14 20:06:46 +01:00
Martin Kleusberg
5dc59feeea Add a comment 2019-01-14 20:03:15 +01:00
Martin Kleusberg
a0b87688ab dbhub: Attempt to fix the OK button in the Push dialog
The OK button in the Remote Push dialog sometimes needed to be clicked
twice in order to work. That's because whenever the Database Name field
loses focus, we would send out a request for the updated branch list.
While processing this request the OK button is effectively disabled by
Qt. This commit aims for an easy fix by changing the request to happen
whenever the text in the Name field changes. This way the timing is a
lot less sensitive. We will need to see however if this introduces other
timing issues for users with slow Internet connections.
2019-01-13 16:32:34 +01:00
Petr Tykal
623a4d6631 New Czech translations (#1710) 2019-01-12 21:36:56 +01:00
mgrojo
8f32d15204 Added icon for foreign-key fields
Fields having a foreign-key constraint are shown with a distinctive icon.

New icon based on page_green.png and bullet_key.png from the Silk icon set.

See comment in issue #192
2019-01-12 21:19:15 +01:00
mgrojo
f5011a233b "Save Project" to remember filename and new "Save Project As" action
"Save Project" remembers used filename, at second and successive calls
the user is not asked for the filename. Ellipsis are removed, since it
only opens a dialog the first time.

A Wait Cursor is set while saving so the user does not get the impression
that pressing "Save Project" does nothing.

"Save Project As" action is added, so the user can still save to another
filename when saved for the first time. Added icon combining package.png
and textfield_rename.png from the Silk icon set.

The base filename for a new project does not include the DB suffix.

Problems saving the project file are detected and the user warned.

See issue #1706
2019-01-11 21:53:45 +01:00
mgrojo
8bf68af047 Add source code locations to Portuguese translation file
Otherwise linguist doesn't show the widgets or source code references.

See PR #1707
2019-01-10 23:29:49 +01:00
Justin Clift
c6e7ca1121 Nuke the AppImage stuff until we have time to investigate the failures 2019-01-09 13:21:44 +11:00
GortiZ
61596adbce Merge e completamento traduzione italiana (#1705) 2019-01-09 13:21:20 +11:00
mgrojo
85ad623c09 Merge updated Spanish translation for v3.11.x (Fix possible resource leaks)
This is an update of the translation file followed by a manual merge of
0ab9f44ce6

See issue #1691
2019-01-03 17:54:32 +01:00
mgrojo
d6edcc08ac Merge updated Spanish translation for v3.11.x
- New SQLcipher dialog strings
- Extensions filter
- Remove translation for Alt+Del, since it has to match the official Qt
translation and it changes between versions. When the shortcut isn't
changed, it is better to not translate the shortcut at all.

# Conflicts:
#	src/translations/sqlb_es_ES.ts
2019-01-03 17:42:16 +01:00
mgrojo
ea6cf146c7 Cmd+Backspace should delete from cursor to the beginning of line on macOS
See issue #815
2019-01-03 00:40:40 +01:00
mgrojo
fc7f2b9440 Align Mac shortcut in Scintilla to standard and Qt for Alt+Backspace
In Mac the standard shortcut for deleting word to the left is Alt+Backspace
so we set this key sequence in Scintilla editors as alternate for Mac.

Reference:

http://doc.qt.io/qt-5/qkeysequence.html
Section Standard Shortcuts:
DeleteStartOfWord	is Alt+Backspace in macOS column.

See issue #815
2019-01-02 21:37:26 +01:00
mgrojo
bf5eaa7330 Replace link style from pragma labels to an embedded icon with link
Even after having removed the hard-coded style from the link texts, this
combination of hyperlink over regular window background is not giving good
results in some dark theme colours. It is uncommon to have this combination
in GUI applications.

The link in the label has been replaced by a link in an embedded icon.

In order to be still recognisable as a link (apart from the hand icon) the
link hover signal is connected to a slot showing the link in the status bar
for 5 seconds.

See issue #1493
2018-12-30 13:30:36 +01:00
Navdeep Singh Sidhu
b7b6bc88a0 Merge pull request #1698 from deepsidhu1313/master
Added support to build x86_64 AppImages  using xenial on Travis CI
2018-12-29 23:47:57 -06:00
Navdeep Singh Sidhu
17ea0cc35a Fixed indent in travis.yml file 2018-12-29 23:44:44 -06:00
Navdeep Singh Sidhu
0601571e48 Updated AppImage versioning to include count from HEAD 2018-12-29 19:18:21 -06:00
Navdeep Singh Sidhu
21c6ea05fb Merge pull request #7 from sqlitebrowser/master
Changes from upstream before PR
2018-12-29 19:05:01 -06:00
Navdeep Singh Sidhu
da3db8bfbf AppImage built support via Travis using xenial
* Updated travis config to use xenial instead of trusty
* Added support to build x86_64 AppImage
2018-12-29 19:02:04 -06:00
mgrojo
1925ccfd37 Make the Edit Cell Dock to update with the selected cell in SQL results
The same connection done for the Browse Data table is done for the SQL
results table so they behave in the same way.

See issue #481
2018-12-28 18:11:44 +01:00
mgrojo
a9de3d87e3 Fix tabs not showing in a clean installation
If there are no settings previously stored for the MainWindow/openTabs, the
default empty string was converted to a list of one empty string and
consequently all tabs were cleared and none added.

This fixes all possible cases where the list of open tabs is empty. It
means: do not make changes, as originally designed (since the setting for
all tabs closed doesn't make sense).

See issue #1692 (and #1675 for the enhancement).
2018-12-28 15:47:11 +01:00
mgrojo
8f59d3aed6 Make Ctrl+T shortcut to work for "Open tab" in "Execute SQL"
This shortcut was set for the following actions, making it ambiguous:
"View > DB Toolbar" and "Open tab" in "Execute SQL". Additionally it was
used by QScintilla for transposing lines.

Shortcut for "View > DB Toolbar" has been removed, since it's not
considered a frequently used action and there are other toolbars without
shortcut. The shortcut for QScintilla has been changed to "Ctrl+Shift+Up".

The now working shortcut is added to the "Open tab" action's tool-tip for
documentation purposes.

See issue #1647
2018-12-28 13:04:17 +01:00
mgrojo
0ffed5e287 Fix shortcuts Alt+[1-4] switching to that tab
Using QShortcut this shortcuts are working in any context. With the
previous approach there were problems in QScintilla widgets, in the Browse
table combo-box and probably others.

See issue #788
2018-12-27 17:45:45 +01:00
mgrojo
ea5a32c37b Fix ambiguous shortcut for Ctrl+O
Ctrl+O for opening a database file did no longer work. It raised this
warning:

QAction::eventFilter: Ambiguous shortcut overload: Ctrl+O

The shortcut was repeated in the UI.

This bug was introduced by e11b32ed54

It was laterally reported in #459
2018-12-27 16:22:41 +01:00
Martin Kleusberg
45a82252e1 Fix possible resource leaks
See issue #1691.
2018-12-27 11:55:21 +01:00
Martin Kleusberg
730b494ce7 Show warning when closing the database fails 2018-12-27 11:30:53 +01:00
mgrojo
544ed812e2 Reset Window Layout, positional shortcuts for tabs and avoid statusTip
- New action (Alt+0) in View menu for resetting window layout (main tabs,
toolbars and docks).
- Shortcuts for tabs use positional meaning: after moving the tabs, the
number always refers to the position of the tab, and not the identity.
- Avoid using statusTip for restoring the original tab label and use
accesibleName, which is believed to be either neutral, when set, or
beneficial.
- Assure the tab is open when some function switches to it: browse table
and SQLite checks.
- Avoid flickering while clearing and adding tabs.

See issue #1675
2018-12-26 19:04:09 +01:00
mgrojo
b89adc4122 Save open tabs state in project files
The ordered set of open tabs is saved in the project file using a new
element main_tabs with attributes open (ordered list of open tabs like the
"MainWindow/openTabs" setting) and current (the current index inside that
set).

When the project load code finds the old element (current_tab) it falls
back to restoring all the main tabs and then setting that tab index as
current. In this way, old project files are restored as they were saved,
even when the user has closed or moved some tabs.

See issue #1675.
2018-12-26 15:03:11 +01:00
Martin Kleusberg
fc8f23f299 Add a comment about a problem we should fix one day 2018-12-26 13:46:28 +01:00
Martin Kleusberg
285e0ef49e Remove unused code and fix a warning 2018-12-26 13:38:42 +01:00
Martin Kleusberg
7f597d07e4 Fix handling of custom rowids/pseudo PKs
This should avoid double queries in the Browse Data tab for views and
for tables.
2018-12-26 13:35:11 +01:00
mgrojo
4f9c21f83f Closable main tabs and saving automatically open tabs and order
Main tabs are made closable, so they can be closed by the user. New entries
are added to the View menu for toggling their open/closed state.

Spartan users can closed all tabs but their preferred, and then the tab bar
is hidden saving some space.

The set of open tabs and their order is automatically saved in the settings
on application exit and restored on application start.

Tab labels are stored in the statusTip attribute in order to restore them,
since those labels are not stored anywhere else.

See issues #1675 and #459
2018-12-25 21:12:28 +01:00
Martin Kleusberg
79ffd779b9 Show current platform and destination platform information
Add the destination platform from the compilation process and the
platform we are running on to the About dialog and the Bug Report
template text.

See issue #1660.
2018-12-25 19:42:55 +01:00
Martin Kleusberg
c8ef76241d Do not recreate table schema if table did not change
When the table schema was not modified in the Edit Table dialog, do not
do anything when clicking the OK button.

See issue #1686.
2018-12-25 18:51:36 +01:00
Martin Kleusberg
094a6a624a Fix plot
Fix a plot bug introduced in 37a5645bf5 by
an oversight.

See issue #1679.
2018-12-25 18:46:29 +01:00
Martin Kleusberg
73f7cc824f Fix 195d8683e5
Some parts of the code were still using indices instead of widget
pointers for referencing the main window tabs.
2018-12-25 17:50:11 +01:00
Justin Clift
dd1878c81e Use Qt 5.11.3 for the macOS builds too
This is due to a weird word wrapping bug present in Qt 5.12.0.

We'll use the Qt 5.11.x releases for now, until a solution to the
problem is found.
2018-12-24 21:51:12 +11:00
mgrojo
195d8683e5 Enable the movable attribute for main tabs
The movable attribute for the main tabs is enabled and the code is adapted
to use widget references instead of indices.

This allows user to move tabs and set a preferred order, but the order is
still not saved.

See issue #1675
2018-12-24 00:56:44 +01:00
zvova7890
a983248931 Change UI size policy, make RU translation shorter (#1678)
The width of the UI elements is forced by the text in buttons. This is a problem in some translations,
where the text are longer than the original. This PR address this tweaking some aspects:

* change UI size policy

* make RU translation for some buttons shorter

* move Set as NULL to bottom in EditDialog
2018-12-23 12:31:06 +01:00