Support text in different encoding in Browse Data tab

When browsing and editing a table in the Browse Data tab allow the user
to change the assumed encoding of the text in the table. We'll then try
to convert from this encoding to Unicode for display purposes and to
convert from Unicode to this encoding for editing purposes. This way the
UI and all tools will keep using Unicode while the database format is
still respected. I hope the amount conversions generated this way won't
affect the performance too much.

See issue #414.
This commit is contained in:
Martin Kleusberg
2015-09-15 00:14:55 +02:00
parent 1ebecbbc9d
commit eaf6ff1565
5 changed files with 94 additions and 9 deletions

View File

@@ -324,8 +324,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>514</width>
<height>579</height>
<width>506</width>
<height>558</height>
</rect>
</property>
<layout class="QFormLayout" name="formLayout">
@@ -1779,6 +1779,14 @@
<string>Toggle the visibility of the rowid column</string>
</property>
</action>
<action name="actionSetTableEncoding">
<property name="text">
<string>Set encoding</string>
</property>
<property name="toolTip">
<string>Change the encoding of the text in the table cells</string>
</property>
</action>
</widget>
<customwidgets>
<customwidget>
@@ -2734,6 +2742,22 @@
</hint>
</hints>
</connection>
<connection>
<sender>actionSetTableEncoding</sender>
<signal>triggered()</signal>
<receiver>MainWindow</receiver>
<slot>browseDataSetTableEncoding()</slot>
<hints>
<hint type="sourcelabel">
<x>-1</x>
<y>-1</y>
</hint>
<hint type="destinationlabel">
<x>518</x>
<y>314</y>
</hint>
</hints>
</connection>
</connections>
<slots>
<slot>fileOpen()</slot>
@@ -2792,5 +2816,6 @@
<slot>jumpToRow(QString,QString,QByteArray)</slot>
<slot>editDataColumnDisplayFormat()</slot>
<slot>showRowidColumn(bool)</slot>
<slot>browseDataSetTableEncoding()</slot>
</slots>
</ui>