66 Commits

Author SHA1 Message Date
4d47af1e9e Code cosmetic:
* Sanitize main unit from unused variables
* Move global variables to public scope
* Bring public vars into some reasonable order
* Move constants to const.inc, unless dependent from some used VCL unit
2010-01-10 17:11:42 +00:00
a4652d39a4 * Fix compiler warnings due to implicit AnsiString to (Unicode)String or vice versa
* Remove workaround for Unicode text to and from clipboard
* Fix writing/reading wrong encoded text into/from registry - no need to use Utf8Encode() any longer
* Implement TMySQLQuery.ColAsAnsi() for cases in which we read binary data.
2010-01-07 00:00:56 +00:00
7d401ffde8 Upgrade to Delphi 2010:
* Removes TNT Unicode controls, which are no longer required. All VCL controls now have native Unicode support.
* Remove Delphi 11 packages, otherwise we would either need to keep TNT or break Unicode
* PngComponents update from Uwe Raabe on http://cc.embarcadero.com/Item/26127
* Adjust auto build process
* Since Delphi 2009, Strings are now UnicodeStrings, not AnsiStrings any longer. Fix a bunch of compiler errors which came along with this change.
TODO: Project should compile but give tons of compiler warnings.
2010-01-05 23:14:33 +00:00
0e29eda7ac Add preference option to use locale number format for CSV+XML+HTML exports. Mainly to work around an Excel bug, which expects float values to be formatted with locale decimal separator when pasting. Fixes issue #1459. 2009-12-08 09:14:42 +00:00
0c83491ed5 Implement preference option to adjust tab width in SynMemos. Fixes issue #857. 2009-11-24 19:34:48 +00:00
445c1adefd A THotKey is not able to hold "Tab" or "Shift+Tab" as shortcuts. Use TSynHotKey's instead in preferences dialog which doesn't have this limitation. 2009-09-24 18:52:35 +00:00
ddbb3a8880 TAction shortcuts have to be set manually for the current session. 2009-09-21 23:23:12 +00:00
c6be8dd575 Implement customizing of shortcuts for all available TActions and SynEditor commands. Fixes issue #536. 2009-09-21 23:12:21 +00:00
d09f1380a1 Refactor query tabs code:
* Collect all relevant controls of one query tab and its variables in a new object
* Collect these tab objects into a TObjectList
* Fixes mixed up QueryMemoLineBreakStyle variable - was used for all tabs, now part of the above mentioned object
* Same goes for minor remembering of selected tab on queryhelpers list
* Use filenames on tabs if saved or loaded.
* On tab close ask if content should be saved.
2009-08-19 23:47:59 +00:00
7e9fcc6586 Implement multiple query tabs. Fixes issue #443. 2009-08-03 23:16:16 +00:00
e2b252a906 Implement a new datatype selector for the table editor, including groups, datatype colors and help hints. Fixes issue #1214 and issue #1165 . 2009-07-07 23:31:16 +00:00
ddbee4c536 Implement optional usage statistics call:
* Disabled by default, can be checked in preferences dialog
* If enabled, reports HeidiSQL revision and versions of recently used servers
2009-06-20 22:10:08 +00:00
2b8e3ac271 Issue #1074: Make maximum number of total rows displayed in datagrid configurable 2009-04-08 20:16:33 +00:00
2cbf85918f Add "Factory defaults" button to preferences dialog. Erases all registry values in HKCU\Software\HeidiSQL\* . Not recursive, as that would also delete sessions and their specific, automatic settings. 2009-04-05 09:19:25 +00:00
fc433bf38f Add background color feature to SQL highlighting via preferences 2009-03-31 22:57:08 +00:00
ab8171ee53 Fix AV if user clicks on sample SynMemo but doesn't hit any attribute representer. 2009-03-31 22:38:50 +00:00
cafd2a8c16 Enhancement in preferences dialog, SQL styles:
* Use AttrCount and Attribute[x] in SynEditHighlighters to iterate through available attributes, instead of doing less with more code.
* Use integer registry values for highlighter colors (were strings) and also integers for bold, italic, underline, strikeout (was one boolean per attribute).
a) optimizes registry access b) normalizes registry names and c) simplifies code. Unfortunately this breaks everyone's customized highlighter style - hopefully ok to do this is in an interim build.
2009-03-31 22:24:00 +00:00
dc9d55fbe8 Recycle preferences form so certain things can be initialized once in FormCreate instead of each time the dialog is called. The selected tab is remembered after the dialog is closed now. FormShow keeps fetching registry values each time the dialog is opened, so, if the user cancels, the next time the dialog is shown, all modified options are reset (which is the correct meaning of "cancel"). 2009-03-26 23:33:07 +00:00
992e2a4236 Fix issue #953: Add checkbox to toggle bold font in SQL font preferences. Also adds italic option for all attributes. 2009-03-18 21:51:06 +00:00
36c8937abb Remove feature "Prefer SHOW TABLES for performance reasons" and support for pre 3.23 servers
* Leads to unpredictable errors in special cases
* Advantage over SHOW TABLE STATUS is hardly measurable
* Makes integrating stored routines into the database tab complex and unstable for the benefit of nothing
2009-03-01 10:34:39 +00:00
da6606f9bc Always keep OK button enabled in preferences dialog. Seems to confuse users and lead to wrong bugreports. 2009-02-14 08:51:14 +00:00
1f6e894ba5 Implement a preference option to limit the size of "Copy as CSV/HTML/XML/SQL" actions. Helps with bug #793: app freezes when 'copy as csv/xml/html' is selected. 2009-01-18 22:32:31 +00:00
909d31fd64 Simplify writing settings to registry:
* Keep only one TRegistry object in memory instead of creating a new one in each routine.
* Move out relevant functions and TRegistry object from main to helpers to make them usable globally.
2009-01-03 17:16:11 +00:00
f1b3f5501f Remove last traces of MDI (issue #513). Merges code, controls and events from childwin into main. 2009-01-01 23:24:36 +00:00
e6b3788924 Implement selection of pulldown attribute by click into SynMemo 2008-12-16 21:19:18 +00:00
d97ac10323 Work around access violation in SynEdit by postponing change event to OnExit (bug #914) 2008-12-16 10:45:23 +00:00
32fad96276 The new inplace editor neutralizes the need for a preference option "Enable popup text editor". Remove it. 2008-11-25 19:35:02 +00:00
b4f4942509 Implement rfe #816: wrong font in SQL log and query tab line numbers 2008-10-22 18:30:03 +00:00
a591edebac Fix bug #714: Impossible to change limit^H^H^H^H^H^H sort order by implementing a fourth button with dropdown menu, enabling the user to save all query elements in one settings. 2008-10-16 23:49:17 +00:00
d70ec31ca4 Work around bug #794: OK + Apply buttons enabled after just switching to a different tab
The bug seems caused by any TUpDown + TEdit which fire OnChange when they get visible for the first time. PageControl.OnChanging + .OnChange help here.
2008-10-12 09:56:02 +00:00
4cf1864921 Enable customizing SQL colors for identifiers, delimited identifiers, conditional comments and symbols. 2008-10-08 19:12:20 +00:00
5b4f5f1b5c Preferences dialog, SQL tab, enhancing color coding and font selection:
* Remove sub tabs
* Replace the color panels by a combobox showing which item is to be changed and a color combo box.
* Add a SynMemo, displaying color and font changes immediately using some sample SQL text.
2008-10-07 22:33:48 +00:00
026df1d4c9 Cosmetic face-lift on preferences dialog:
* Normalize component names
* Apply and use modal results to OK and Cancel buttons
* Fix apply button to be enabled after changing NULL color
* Fix all tab orders
* Fix cut labels on Vista
* Also disable btnOK after applying changes
* Find better/shorter captions for main tabs
* Remove form borders and apply 8px edge margins instead
2008-10-06 21:25:33 +00:00
fd9c44b576 Implement background colors for NULL fields, part 2 of rfe #692 2008-09-23 23:20:20 +00:00
0ef84eb62f Implement preference options to enable/disable the new SET editor, plus color selection for the grid font in SET fields. 2008-09-23 22:33:06 +00:00
d2f354275b Fix name, default value and meaning of preference option "Maximum column width". By default it's 300 now. 2008-09-11 22:44:28 +00:00
48a0f43644 Get rid of no longer used includes. 2008-09-09 21:44:19 +00:00
efbadf5b58 Fulfill rfe #692 "Add color-coding settings to data-appearance tab in preferences". Including new default color for ENUM fields and settings to enable/disable the grid editors. 2008-09-07 15:13:24 +00:00
5aa13c8195 Preferences dialog: Make data appearance options more compact, giving room for coming data color + editor options. Rename components reasonably. 2008-09-07 09:03:59 +00:00
1a3031414a * DPI fix: The node height of editable Virtual Trees was still not optimal as an editing node didn't have enough height to show the editing cursor. Steal some code from StdCtrls.TCustomEdit.AdjustHeight which does basically what we need here.
* Detected the VirtualTree.Header.ParentFont property and activated that instead of fixing the header font in FixVT
2008-09-06 18:38:51 +00:00
1defb9eaa6 * Bugfix: default enclose/separate for CSV should be " and ;. Takes care of export part of issue #709.
* Indicate in CSV files which rows need to be UNHEX()ed with LOAD DATA INFILE during import.  Takes care of export part of issue #709.
* Optimization: stop copying records and arrays to stack where appropriate.  See also note in helpers.pas.
* Factor out code to extract a cell in it's full width into EnsureFullWidth().
* Create method DiscardData() to release memory for a row.
* Bugfix: GridTo{Xml,Csv,Html} did not export cells in their full widths; they do now.  Fixes remainder of issue #685.
* Bugfix: remove superfluous field separator at end of each CSV record.
* Bugfix: CSV field enclose characters within field data must be escaped by printing the enclose character twice, as per de-facto (is it a standard when there are hundreds of applications supporting it, but *all* the major ones all come from the same company?..) CSV.
* Indicate in CSV files which cells are NULL by removing field enclosing (non-standard MySQL CSV extension).
* Indicate in XML files which cells are null and which cells are in hexadecimal format.
* Bugfix: always escape <, &, > in HTML and XML files.
2008-09-03 21:53:45 +00:00
9a52593dc2 Use Vista's Segeo font for all forms by using the SetVistaFonts() in mainform plus the new routine InheritFont() which simply overtakes fontname and size from the mainform to all other forms. 2008-08-29 18:20:14 +00:00
2cff5732fc Remove no longer needed routine for autocalculating row limit: GetCalculatedLimit. The Export SQL dialog now uses a constant number of 5000 rows fetched per step. Also removes the option in the preferences screen for limiting the data amount, which was misleading the user before and only used to limit the export stuff. 2008-08-26 09:09:41 +00:00
aa0bd953c6 Replace TNTDBGrids with VirtualTrees to enhance grid viewing and editing.
Affected issues: rfe #618, rfe #464, bug #324, bug #635 (maybe more)
Breaks: Unicode grid editing (due to yet unsolved bug #620), enum pulldowns, MEMO editing
Major changes:
  - editor tab at bottom completely removed, SQL log is always visible now.
  - memo, blob and enum editors don't have a replacement yet. This is left for later commits.
  - grid cells are colorized to signalize their datatypes
  - UPDATEs, DELETEs and INSERTs are composed by own code, no longer by Zeos internal mechanisms. Should make debugging easier.
  - UPDATEs + DELETEs on tables without unique key are blocked now.
  - editing in the query grid is always blocked. Would need some extensive parser to allow that.
2008-08-03 19:30:07 +00:00
e45c7c3325 Make datasize in LIMIT calculation configurable via preferences (defaults to 5M). Remove rounding to next 1000 in GetCalculatedLimit to avoid overriding low datasize preference. 2008-07-16 22:22:16 +00:00
764f444ebf Clean registry from unwanted WHERE clauses if "Remember WHERE filters" was unchecked. Avoids confusion with unwanted filters when that option was switched OFF and then ON again. 2008-07-14 21:46:38 +00:00
5b0bb48d0a Convert the myriad of redundant menuitems and buttons on the main controlbar + important toolbars in the tabsheets to use TActions. This moves
a) some hundred lines of code from childwin.pas to main.pas
b) redundant hints/captions/shortcuts/events for similar buttons/menuitems to their corresponding TAction in main.dfm .

This change
a) avoids several inconsistent captions like described in issue #595
b) makes it easier to have toolbars on the mainform which are controlled by childform.
2008-07-01 18:59:07 +00:00
80c5d9cdd4 Get rid of secondary, confusing checkbox in preferences window for limiting data rows. 2008-06-17 13:21:17 +00:00
21ada0acc8 Fix setting customized font name and size of filter editor and process viewer. 2008-05-30 04:59:25 +00:00
88d25c902d Add option "Also check for updated nightly builds" to preferences dialog and implement needed logic in updatecheck dialog and main unit. 2008-05-25 19:35:58 +00:00