1. RXDBGrid - in collumn title show number for sort fileds

2. RXDBGrid - in multiline collumn header push button only last line
3. RxDBGrid demo - fix work with filter in table demo

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@2541 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
alexs75
2012-09-26 14:19:29 +00:00
parent 7c25da7b8a
commit ef7bf595fb
4 changed files with 287 additions and 247 deletions

View File

@ -54,17 +54,15 @@
<MinVersion Major="1" Release="18" Build="56" Valid="True"/>
</Item4>
</RequiredPackages>
<Units Count="81">
<Units Count="87">
<Unit0>
<Filename Value="RxDBGridDemo.lpr"/>
<IsPartOfProject Value="True"/>
<UnitName Value="RxDBGridDemo"/>
<EditorIndex Value="3"/>
<WindowIndex Value="0"/>
<TopLine Value="1"/>
<CursorPos X="9" Y="16"/>
<UsageCount Value="66"/>
<Loaded Value="True"/>
<UsageCount Value="78"/>
</Unit0>
<Unit1>
<Filename Value="rxdbgridmainunit.pas"/>
@ -75,9 +73,9 @@
<UnitName Value="RxDBGridMainUnit"/>
<EditorIndex Value="0"/>
<WindowIndex Value="0"/>
<TopLine Value="67"/>
<CursorPos X="21" Y="18"/>
<UsageCount Value="66"/>
<TopLine Value="53"/>
<CursorPos X="1" Y="73"/>
<UsageCount Value="78"/>
<Loaded Value="True"/>
<LoadedDesigner Value="True"/>
</Unit1>
@ -86,27 +84,28 @@
<UnitName Value="db"/>
<TopLine Value="1112"/>
<CursorPos X="17" Y="1116"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit2>
<Unit3>
<Filename Value="../../../fpcsrc/fcl/db/dataset.inc"/>
<TopLine Value="1134"/>
<CursorPos X="21" Y="1139"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit3>
<Unit4>
<Filename Value="../../rxmemds.pas"/>
<UnitName Value="rxmemds"/>
<TopLine Value="337"/>
<CursorPos X="1" Y="356"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit4>
<Unit5>
<Filename Value="../../rxdbgrid.pas"/>
<UnitName Value="rxdbgrid"/>
<TopLine Value="1007"/>
<CursorPos X="51" Y="1022"/>
<UsageCount Value="11"/>
<WindowIndex Value="0"/>
<TopLine Value="3589"/>
<CursorPos X="28" Y="3600"/>
<UsageCount Value="14"/>
<Bookmarks Count="2">
<Item0 X="1" Y="1089" ID="1"/>
<Item1 X="3" Y="1230" ID="2"/>
@ -117,73 +116,73 @@
<UnitName Value="LResources"/>
<TopLine Value="2626"/>
<CursorPos X="1" Y="2644"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit6>
<Unit7>
<Filename Value="../../../lcl/grids.pas"/>
<UnitName Value="Grids"/>
<TopLine Value="385"/>
<CursorPos X="33" Y="394"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit7>
<Unit8>
<Filename Value="../../../lcl/dbgrids.pas"/>
<UnitName Value="DBGrids"/>
<TopLine Value="187"/>
<CursorPos X="30" Y="199"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit8>
<Unit9>
<Filename Value="../../rxpopupunit.pas"/>
<UnitName Value="rxpopupunit"/>
<TopLine Value="246"/>
<CursorPos X="15" Y="249"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit9>
<Unit10>
<Filename Value="../../../lcl/include/wincontrol.inc"/>
<TopLine Value="7217"/>
<CursorPos X="1" Y="7236"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit10>
<Unit11>
<Filename Value="../../../lcl/include/control.inc"/>
<TopLine Value="1"/>
<CursorPos X="1" Y="1"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit11>
<Unit12>
<Filename Value="../../../lcl/lclmessageglue.pas"/>
<UnitName Value="LCLMessageGlue"/>
<TopLine Value="92"/>
<CursorPos X="46" Y="96"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit12>
<Unit13>
<Filename Value="../../../lcl/controls.pp"/>
<UnitName Value="Controls"/>
<TopLine Value="1779"/>
<CursorPos X="60" Y="1798"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit13>
<Unit14>
<Filename Value="../../../install/2/rxdbgrid.diff"/>
<TopLine Value="1"/>
<CursorPos X="1" Y="21"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
<DefaultSyntaxHighlighter Value="Diff"/>
</Unit14>
<Unit15>
<Filename Value="../../../lcl/interfaces/gtk/gtkdevicecontext.inc"/>
<TopLine Value="626"/>
<CursorPos X="1" Y="644"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit15>
<Unit16>
<Filename Value="../../../lcl/interfaces/gtk2/gtk2winapi.inc"/>
<TopLine Value="559"/>
<CursorPos X="1" Y="577"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit16>
<Unit17>
<Filename Value="../../rxdbgrid_columsunit.pas"/>
@ -193,75 +192,75 @@
<UnitName Value="rxdbgrid_columsunit"/>
<TopLine Value="26"/>
<CursorPos X="46" Y="45"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit17>
<Unit18>
<Filename Value="../../rxdconst.pas"/>
<UnitName Value="rxdconst"/>
<TopLine Value="126"/>
<CursorPos X="15" Y="155"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit18>
<Unit19>
<Filename Value="../../../lcl/include/winapih.inc"/>
<TopLine Value="211"/>
<CursorPos X="10" Y="223"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit19>
<Unit20>
<Filename Value="../../backup/rxdbgrid.pas"/>
<UnitName Value="rxdbgrid"/>
<TopLine Value="1207"/>
<CursorPos X="1" Y="1227"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit20>
<Unit21>
<Filename Value="../../rxaboutdialog.pas"/>
<UnitName Value="RxAboutDialog"/>
<TopLine Value="10"/>
<CursorPos X="73" Y="30"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit21>
<Unit22>
<Filename Value="../../registerrx.pas"/>
<UnitName Value="registerrx"/>
<TopLine Value="174"/>
<CursorPos X="18" Y="201"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit22>
<Unit23>
<Filename Value="../../../ideintf/idewindowintf.pas"/>
<UnitName Value="IDEWindowIntf"/>
<TopLine Value="31"/>
<CursorPos X="1" Y="1"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit23>
<Unit24>
<Filename Value="../../../lcl/extdlgs.pas"/>
<UnitName Value="ExtDlgs"/>
<TopLine Value="105"/>
<CursorPos X="35" Y="122"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit24>
<Unit25>
<Filename Value="../../../lcl/dialogs.pp"/>
<UnitName Value="Dialogs"/>
<TopLine Value="62"/>
<CursorPos X="21" Y="79"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit25>
<Unit26>
<Filename Value="../../../lcl/include/commondialog.inc"/>
<TopLine Value="80"/>
<CursorPos X="17" Y="84"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit26>
<Unit27>
<Filename Value="../../../lcl/widgetset/wsdialogs.pp"/>
<UnitName Value="WSDialogs"/>
<TopLine Value="132"/>
<CursorPos X="3" Y="136"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit27>
<Unit28>
<Filename Value="../../rxaboutformunit.pas"/>
@ -270,41 +269,41 @@
<UnitName Value="rxAboutFormUnit"/>
<TopLine Value="41"/>
<CursorPos X="26" Y="55"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit28>
<Unit29>
<Filename Value="../../rxversinfo.pas"/>
<UnitName Value="RxVersInfo"/>
<TopLine Value="72"/>
<CursorPos X="49" Y="105"/>
<UsageCount Value="7"/>
<UsageCount Value="6"/>
</Unit29>
<Unit30>
<Filename Value="../../../lcl/buttonpanel.pas"/>
<UnitName Value="ButtonPanel"/>
<TopLine Value="11"/>
<CursorPos X="6" Y="15"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit30>
<Unit31>
<Filename Value="../../../lcl/extctrls.pp"/>
<UnitName Value="ExtCtrls"/>
<TopLine Value="604"/>
<CursorPos X="15" Y="607"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit31>
<Unit32>
<Filename Value="../../../lcl/include/customimage.inc"/>
<TopLine Value="67"/>
<CursorPos X="3" Y="69"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit32>
<Unit33>
<Filename Value="../../../install/fpcsrc/rtl/objpas/classes/classesh.inc"/>
<WindowIndex Value="0"/>
<TopLine Value="426"/>
<CursorPos X="17" Y="448"/>
<UsageCount Value="15"/>
<UsageCount Value="14"/>
</Unit33>
<Unit34>
<Filename Value="../../../smsprog/sms_send_deamon/smsSendGui/smssendaboutunit.pas"/>
@ -314,21 +313,21 @@
<UnitName Value="smsSendAboutUnit"/>
<TopLine Value="28"/>
<CursorPos X="1" Y="57"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit34>
<Unit35>
<Filename Value="../../../smsprog/sms_shared/smsabstarctconstunit.pas"/>
<UnitName Value="smsAbstarctConstUnit"/>
<TopLine Value="1"/>
<CursorPos X="42" Y="11"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit35>
<Unit36>
<Filename Value="../../rxconst.pas"/>
<UnitName Value="rxconst"/>
<TopLine Value="34"/>
<CursorPos X="3" Y="51"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit36>
<Unit37>
<Filename Value="../../../rxnet/demo/send_demo/smssendparamsunit.pas"/>
@ -338,7 +337,7 @@
<UnitName Value="smssendParamsUnit"/>
<TopLine Value="49"/>
<CursorPos X="34" Y="60"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit37>
<Unit38>
<Filename Value="../../../rxnet/demo/send_demo/smssenddemomainunit.pas"/>
@ -348,49 +347,49 @@
<UnitName Value="smsSendDemoMainUnit"/>
<TopLine Value="41"/>
<CursorPos X="105" Y="29"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit38>
<Unit39>
<Filename Value="../../../rxnet/demo/send_demo/send_demo.lpr"/>
<UnitName Value="send_demo"/>
<TopLine Value="1"/>
<CursorPos X="1" Y="1"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit39>
<Unit40>
<Filename Value="../../../doceditor/lazdeopts.pp"/>
<UnitName Value="LazDEOpts"/>
<TopLine Value="43"/>
<CursorPos X="1" Y="56"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit40>
<Unit41>
<Filename Value="../../rxfileutils.pas"/>
<UnitName Value="rxFileUtils"/>
<TopLine Value="18"/>
<CursorPos X="33" Y="42"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit41>
<Unit42>
<Filename Value="../../registerrxdb.pas"/>
<UnitName Value="RegisterRxDB"/>
<TopLine Value="2"/>
<CursorPos X="20" Y="17"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit42>
<Unit43>
<Filename Value="../../../ideintf/dbpropedits.pas"/>
<UnitName Value="DBPropEdits"/>
<TopLine Value="13"/>
<CursorPos X="6" Y="19"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit43>
<Unit44>
<Filename Value="../../../ideintf/propedits.pp"/>
<UnitName Value="PropEdits"/>
<TopLine Value="1"/>
<CursorPos X="6" Y="26"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit44>
<Unit45>
<Filename Value="../../rxdbgrid_findunit.pas"/>
@ -400,7 +399,7 @@
<UnitName Value="rxdbgrid_findunit"/>
<TopLine Value="78"/>
<CursorPos X="1" Y="94"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit45>
<Unit46>
<Filename Value="../../rxtoolbar.pas"/>
@ -408,7 +407,7 @@
<WindowIndex Value="0"/>
<TopLine Value="1"/>
<CursorPos X="52" Y="26"/>
<UsageCount Value="10"/>
<UsageCount Value="9"/>
</Unit46>
<Unit47>
<Filename Value="../../../synedit/synedit.pp"/>
@ -416,7 +415,7 @@
<WindowIndex Value="0"/>
<TopLine Value="5699"/>
<CursorPos X="1" Y="5702"/>
<UsageCount Value="15"/>
<UsageCount Value="14"/>
</Unit47>
<Unit48>
<Filename Value="../../../synedit/syneditkeycmds.pp"/>
@ -424,14 +423,14 @@
<WindowIndex Value="0"/>
<TopLine Value="750"/>
<CursorPos X="3" Y="752"/>
<UsageCount Value="11"/>
<UsageCount Value="10"/>
</Unit48>
<Unit49>
<Filename Value="../../../install/fpcsrc/rtl/objpas/classes/classes.inc"/>
<WindowIndex Value="0"/>
<TopLine Value="429"/>
<CursorPos X="33" Y="447"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit49>
<Unit50>
<Filename Value="../../../lcl/actnlist.pas"/>
@ -439,7 +438,7 @@
<WindowIndex Value="0"/>
<TopLine Value="206"/>
<CursorPos X="33" Y="224"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit50>
<Unit51>
<Filename Value="../../../lcl/lclproc.pas"/>
@ -447,14 +446,14 @@
<WindowIndex Value="0"/>
<TopLine Value="1154"/>
<CursorPos X="10" Y="1165"/>
<UsageCount Value="8"/>
<UsageCount Value="7"/>
</Unit51>
<Unit52>
<Filename Value="rxdbgridmainunit.lfm"/>
<WindowIndex Value="0"/>
<TopLine Value="133"/>
<CursorPos X="5" Y="103"/>
<UsageCount Value="9"/>
<UsageCount Value="8"/>
<DefaultSyntaxHighlighter Value="LFM"/>
</Unit52>
<Unit53>
@ -462,14 +461,14 @@
<WindowIndex Value="0"/>
<TopLine Value="286"/>
<CursorPos X="1" Y="288"/>
<UsageCount Value="14"/>
<UsageCount Value="13"/>
</Unit53>
<Unit54>
<Filename Value="../../../wine/1/1/rx.diff"/>
<WindowIndex Value="0"/>
<TopLine Value="1"/>
<CursorPos X="1" Y="9"/>
<UsageCount Value="9"/>
<UsageCount Value="8"/>
<DefaultSyntaxHighlighter Value="Diff"/>
</Unit54>
<Unit55>
@ -478,14 +477,14 @@
<WindowIndex Value="0"/>
<TopLine Value="541"/>
<CursorPos X="1" Y="569"/>
<UsageCount Value="9"/>
<UsageCount Value="8"/>
</Unit55>
<Unit56>
<Filename Value="../../../lcl/include/canvas.inc"/>
<WindowIndex Value="0"/>
<TopLine Value="1116"/>
<CursorPos X="1" Y="1132"/>
<UsageCount Value="10"/>
<UsageCount Value="9"/>
</Unit56>
<Unit57>
<Filename Value="../../exsortsql.pas"/>
@ -493,42 +492,43 @@
<WindowIndex Value="0"/>
<TopLine Value="69"/>
<CursorPos X="49" Y="3"/>
<UsageCount Value="9"/>
<UsageCount Value="8"/>
</Unit57>
<Unit58>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<UnitName Value="rxdbgrid"/>
<EditorIndex Value="4"/>
<EditorIndex Value="1"/>
<WindowIndex Value="0"/>
<TopLine Value="167"/>
<CursorPos X="15" Y="186"/>
<UsageCount Value="17"/>
<TopLine Value="419"/>
<CursorPos X="15" Y="482"/>
<UsageCount Value="20"/>
<Bookmarks Count="4">
<Item0 X="18" Y="3871" ID="1"/>
<Item1 X="1" Y="2184" ID="2"/>
<Item0 X="18" Y="3902" ID="1"/>
<Item1 X="1" Y="2206" ID="2"/>
<Item2 X="15" Y="633" ID="3"/>
<Item3 X="17" Y="3741" ID="4"/>
<Item3 X="17" Y="3772" ID="4"/>
</Bookmarks>
<Loaded Value="True"/>
</Unit58>
<Unit59>
<Filename Value="/usr/local/share/lazarus/lcl/dbgrids.pas"/>
<UnitName Value="DBGrids"/>
<EditorIndex Value="5"/>
<IsVisibleTab Value="True"/>
<EditorIndex Value="2"/>
<WindowIndex Value="0"/>
<TopLine Value="401"/>
<CursorPos X="15" Y="420"/>
<UsageCount Value="11"/>
<TopLine Value="433"/>
<CursorPos X="15" Y="476"/>
<UsageCount Value="13"/>
<Loaded Value="True"/>
</Unit59>
<Unit60>
<Filename Value="/usr/local/share/lazarus/lcl/grids.pas"/>
<UnitName Value="Grids"/>
<EditorIndex Value="6"/>
<EditorIndex Value="3"/>
<WindowIndex Value="0"/>
<TopLine Value="11347"/>
<CursorPos X="3" Y="11349"/>
<UsageCount Value="11"/>
<TopLine Value="3779"/>
<CursorPos X="31" Y="3814"/>
<UsageCount Value="16"/>
<Loaded Value="True"/>
</Unit60>
<Unit61>
@ -536,7 +536,7 @@
<WindowIndex Value="0"/>
<TopLine Value="1554"/>
<CursorPos X="38" Y="1569"/>
<UsageCount Value="9"/>
<UsageCount Value="8"/>
</Unit61>
<Unit62>
<Filename Value="/usr/local/share/lazarus/lcl/buttons.pp"/>
@ -544,7 +544,7 @@
<WindowIndex Value="0"/>
<TopLine Value="333"/>
<CursorPos X="3" Y="360"/>
<UsageCount Value="9"/>
<UsageCount Value="8"/>
</Unit62>
<Unit63>
<Filename Value="../../../../../../install/fpcsrc/packages/fcl-db/src/base/db.pas"/>
@ -552,7 +552,7 @@
<WindowIndex Value="0"/>
<TopLine Value="1588"/>
<CursorPos X="15" Y="1609"/>
<UsageCount Value="9"/>
<UsageCount Value="8"/>
</Unit63>
<Unit64>
<Filename Value="/usr/local/share/lazarus/components/rxnew/vclutils.pas"/>
@ -560,14 +560,14 @@
<WindowIndex Value="0"/>
<TopLine Value="1"/>
<CursorPos X="1" Y="35"/>
<UsageCount Value="11"/>
<UsageCount Value="10"/>
</Unit64>
<Unit65>
<Filename Value="/usr/local/share/lazarus/lcl/include/canvas.inc"/>
<WindowIndex Value="0"/>
<TopLine Value="1317"/>
<CursorPos X="1" Y="1338"/>
<UsageCount Value="9"/>
<UsageCount Value="8"/>
</Unit65>
<Unit66>
<Filename Value="/usr/local/share/lazarus/lcl/graphics.pp"/>
@ -575,21 +575,21 @@
<WindowIndex Value="0"/>
<TopLine Value="93"/>
<CursorPos X="3" Y="99"/>
<UsageCount Value="10"/>
<UsageCount Value="9"/>
</Unit66>
<Unit67>
<Filename Value="/usr/local/share/lazarus/lcl/include/lclintf.inc"/>
<WindowIndex Value="0"/>
<TopLine Value="132"/>
<CursorPos X="1" Y="155"/>
<UsageCount Value="9"/>
<UsageCount Value="8"/>
</Unit67>
<Unit68>
<Filename Value="/usr/local/share/lazarus/lcl/interfaces/gtk2/gtk2lclintf.inc"/>
<WindowIndex Value="0"/>
<TopLine Value="167"/>
<CursorPos X="1" Y="190"/>
<UsageCount Value="9"/>
<UsageCount Value="8"/>
</Unit68>
<Unit69>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxsortby.pas"/>
@ -600,7 +600,7 @@
<WindowIndex Value="0"/>
<TopLine Value="50"/>
<CursorPos X="14" Y="65"/>
<UsageCount Value="11"/>
<UsageCount Value="10"/>
</Unit69>
<Unit70>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxfilterby.pas"/>
@ -611,23 +611,21 @@
<WindowIndex Value="0"/>
<TopLine Value="315"/>
<CursorPos X="1" Y="350"/>
<UsageCount Value="9"/>
<UsageCount Value="8"/>
</Unit70>
<Unit71>
<Filename Value="../../../../../../install/source/fpcsrc/rtl/objpas/classes/classesh.inc"/>
<EditorIndex Value="7"/>
<WindowIndex Value="0"/>
<TopLine Value="255"/>
<CursorPos X="15" Y="271"/>
<UsageCount Value="11"/>
<Loaded Value="True"/>
<UsageCount Value="12"/>
</Unit71>
<Unit72>
<Filename Value="../../../../../../install/source/fpcsrc/rtl/objpas/classes/stringl.inc"/>
<WindowIndex Value="0"/>
<TopLine Value="593"/>
<CursorPos X="3" Y="598"/>
<UsageCount Value="9"/>
<UsageCount Value="8"/>
</Unit72>
<Unit73>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxstrutils.pas"/>
@ -635,199 +633,225 @@
<WindowIndex Value="0"/>
<TopLine Value="140"/>
<CursorPos X="23" Y="168"/>
<UsageCount Value="9"/>
<UsageCount Value="8"/>
</Unit73>
<Unit74>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxlookup.pas"/>
<UnitName Value="rxlookup"/>
<EditorIndex Value="11"/>
<WindowIndex Value="0"/>
<TopLine Value="1176"/>
<CursorPos X="3" Y="1196"/>
<UsageCount Value="14"/>
<Loaded Value="True"/>
<UsageCount Value="15"/>
</Unit74>
<Unit75>
<Filename Value="../../../../../../install/source/fpcsrc/packages/fcl-db/src/base/db.pas"/>
<UnitName Value="db"/>
<EditorIndex Value="10"/>
<WindowIndex Value="0"/>
<TopLine Value="1776"/>
<CursorPos X="14" Y="1796"/>
<UsageCount Value="14"/>
<Loaded Value="True"/>
<UsageCount Value="15"/>
</Unit75>
<Unit76>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxpopupunit.pas"/>
<UnitName Value="rxpopupunit"/>
<EditorIndex Value="12"/>
<WindowIndex Value="0"/>
<TopLine Value="275"/>
<CursorPos X="1" Y="298"/>
<UsageCount Value="14"/>
<Loaded Value="True"/>
<UsageCount Value="15"/>
</Unit76>
<Unit77>
<Filename Value="../../../../../../install/source/fpcsrc/rtl/objpas/classes/collect.inc"/>
<EditorIndex Value="9"/>
<WindowIndex Value="0"/>
<TopLine Value="397"/>
<CursorPos X="3" Y="399"/>
<UsageCount Value="11"/>
<Loaded Value="True"/>
<UsageCount Value="12"/>
</Unit77>
<Unit78>
<Filename Value="../../../../../../install/source/fpcsrc/rtl/objpas/classes/lists.inc"/>
<EditorIndex Value="8"/>
<WindowIndex Value="0"/>
<TopLine Value="131"/>
<CursorPos X="3" Y="133"/>
<UsageCount Value="11"/>
<Loaded Value="True"/>
<UsageCount Value="12"/>
</Unit78>
<Unit79>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxsortmemds.pas"/>
<UnitName Value="rxsortmemds"/>
<EditorIndex Value="1"/>
<WindowIndex Value="0"/>
<TopLine Value="34"/>
<TopLine Value="16"/>
<CursorPos X="1" Y="1"/>
<UsageCount Value="10"/>
<Loaded Value="True"/>
<UsageCount Value="9"/>
</Unit79>
<Unit80>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxmemds.pas"/>
<UnitName Value="rxmemds"/>
<IsVisibleTab Value="True"/>
<EditorIndex Value="2"/>
<WindowIndex Value="0"/>
<TopLine Value="144"/>
<CursorPos X="15" Y="164"/>
<UsageCount Value="10"/>
<Loaded Value="True"/>
<TopLine Value="1629"/>
<CursorPos X="3" Y="1641"/>
<UsageCount Value="9"/>
</Unit80>
<Unit81>
<Filename Value="../../../../lcl/graphics.pp"/>
<UnitName Value="Graphics"/>
<EditorIndex Value="4"/>
<WindowIndex Value="0"/>
<TopLine Value="524"/>
<CursorPos X="17" Y="542"/>
<UsageCount Value="13"/>
<Loaded Value="True"/>
</Unit81>
<Unit82>
<Filename Value="/usr/local/share/lazarus/lcl/controls.pp"/>
<UnitName Value="Controls"/>
<WindowIndex Value="0"/>
<TopLine Value="1554"/>
<CursorPos X="14" Y="1574"/>
<UsageCount Value="12"/>
</Unit82>
<Unit83>
<Filename Value="/usr/local/share/lazarus/components/rxnew/Demos/RxDBGrid/rxdbgridmainunit.pas"/>
<UnitName Value="RxDBGridMainUnit"/>
<WindowIndex Value="0"/>
<TopLine Value="136"/>
<CursorPos X="1" Y="162"/>
<UsageCount Value="10"/>
</Unit83>
<Unit84>
<Filename Value="/usr/local/share/lazarus/lcl/stdctrls.pp"/>
<UnitName Value="StdCtrls"/>
<WindowIndex Value="0"/>
<TopLine Value="233"/>
<CursorPos X="3" Y="254"/>
<UsageCount Value="10"/>
</Unit84>
<Unit85>
<Filename Value="/usr/local/share/lazarus/lcl/lcltype.pp"/>
<UnitName Value="LCLType"/>
<WindowIndex Value="0"/>
<TopLine Value="1115"/>
<CursorPos X="3" Y="1136"/>
<UsageCount Value="10"/>
</Unit85>
<Unit86>
<Filename Value="/usr/local/share/lazarus/lcl/include/customcontrol.inc"/>
<WindowIndex Value="0"/>
<TopLine Value="70"/>
<CursorPos X="3" Y="79"/>
<UsageCount Value="10"/>
</Unit86>
</Units>
<JumpHistory Count="30" HistoryIndex="29">
<JumpHistory Count="28" HistoryIndex="26">
<Position1>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="453" Column="30" TopLine="441"/>
<Filename Value="rxdbgridmainunit.pas"/>
<Caret Line="153" Column="1" TopLine="153"/>
</Position1>
<Position2>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="629" Column="44" TopLine="610"/>
<Filename Value="rxdbgridmainunit.pas"/>
<Caret Line="265" Column="3" TopLine="262"/>
</Position2>
<Position3>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="1590" Column="3" TopLine="1586"/>
<Caret Line="3300" Column="3" TopLine="3297"/>
</Position3>
<Position4>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="1519" Column="23" TopLine="1495"/>
<Filename Value="/usr/local/share/lazarus/lcl/grids.pas"/>
<Caret Line="3389" Column="3" TopLine="3381"/>
</Position4>
<Position5>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="436" Column="5" TopLine="415"/>
<Caret Line="3300" Column="3" TopLine="3297"/>
</Position5>
<Position6>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="409" Column="1" TopLine="383"/>
<Filename Value="/usr/local/share/lazarus/lcl/grids.pas"/>
<Caret Line="3403" Column="3" TopLine="3381"/>
</Position6>
<Position7>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="849" Column="19" TopLine="847"/>
<Filename Value="/usr/local/share/lazarus/lcl/grids.pas"/>
<Caret Line="908" Column="27" TopLine="889"/>
</Position7>
<Position8>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="848" Column="1" TopLine="847"/>
<Filename Value="/usr/local/share/lazarus/lcl/grids.pas"/>
<Caret Line="3408" Column="17" TopLine="3373"/>
</Position8>
<Position9>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="410" Column="74" TopLine="402"/>
<Filename Value="/usr/local/share/lazarus/lcl/grids.pas"/>
<Caret Line="3785" Column="35" TopLine="3749"/>
</Position9>
<Position10>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="1585" Column="38" TopLine="1564"/>
<Filename Value="/usr/local/share/lazarus/lcl/grids.pas"/>
<Caret Line="1" Column="1" TopLine="1"/>
</Position10>
<Position11>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="632" Column="15" TopLine="613"/>
<Filename Value="/usr/local/share/lazarus/lcl/grids.pas"/>
<Caret Line="908" Column="27" TopLine="875"/>
</Position11>
<Position12>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="1593" Column="38" TopLine="1581"/>
<Filename Value="/usr/local/share/lazarus/lcl/grids.pas"/>
<Caret Line="3408" Column="17" TopLine="3373"/>
</Position12>
<Position13>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="2069" Column="15" TopLine="2048"/>
<Caret Line="482" Column="15" TopLine="419"/>
</Position13>
<Position14>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="437" Column="5" TopLine="416"/>
<Filename Value="/usr/local/share/lazarus/lcl/dbgrids.pas"/>
<Caret Line="285" Column="3" TopLine="262"/>
</Position14>
<Position15>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="407" Column="1" TopLine="383"/>
<Filename Value="/usr/local/share/lazarus/lcl/dbgrids.pas"/>
<Caret Line="2696" Column="3" TopLine="2691"/>
</Position15>
<Position16>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="2078" Column="2" TopLine="2047"/>
<Filename Value="/usr/local/share/lazarus/lcl/grids.pas"/>
<Caret Line="3788" Column="3" TopLine="3782"/>
</Position16>
<Position17>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="2114" Column="83" TopLine="2095"/>
<Filename Value="/usr/local/share/lazarus/lcl/grids.pas"/>
<Caret Line="923" Column="23" TopLine="904"/>
</Position17>
<Position18>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="2126" Column="12" TopLine="2111"/>
<Filename Value="/usr/local/share/lazarus/lcl/grids.pas"/>
<Caret Line="3791" Column="15" TopLine="3756"/>
</Position18>
<Position19>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="2127" Column="10" TopLine="2109"/>
<Filename Value="/usr/local/share/lazarus/lcl/grids.pas"/>
<Caret Line="3794" Column="13" TopLine="3759"/>
</Position19>
<Position20>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="2227" Column="49" TopLine="2203"/>
<Filename Value="/usr/local/share/lazarus/lcl/grids.pas"/>
<Caret Line="1" Column="1" TopLine="1"/>
</Position20>
<Position21>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="2226" Column="1" TopLine="2203"/>
<Filename Value="/usr/local/share/lazarus/lcl/grids.pas"/>
<Caret Line="923" Column="23" TopLine="890"/>
</Position21>
<Position22>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="538" Column="36" TopLine="522"/>
<Filename Value="/usr/local/share/lazarus/lcl/grids.pas"/>
<Caret Line="3791" Column="15" TopLine="3756"/>
</Position22>
<Position23>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="2163" Column="3" TopLine="2139"/>
<Filename Value="/usr/local/share/lazarus/lcl/grids.pas"/>
<Caret Line="3794" Column="13" TopLine="3759"/>
</Position23>
<Position24>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="2181" Column="38" TopLine="2160"/>
<Filename Value="/usr/local/share/lazarus/lcl/dbgrids.pas"/>
<Caret Line="2696" Column="3" TopLine="2691"/>
</Position24>
<Position25>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="2563" Column="2" TopLine="2534"/>
<Filename Value="/usr/local/share/lazarus/lcl/dbgrids.pas"/>
<Caret Line="1" Column="1" TopLine="1"/>
</Position25>
<Position26>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="472" Column="7" TopLine="453"/>
<Filename Value="/usr/local/share/lazarus/lcl/dbgrids.pas"/>
<Caret Line="395" Column="23" TopLine="361"/>
</Position26>
<Position27>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="2564" Column="2" TopLine="2544"/>
<Filename Value="/usr/local/share/lazarus/lcl/dbgrids.pas"/>
<Caret Line="1283" Column="13" TopLine="1271"/>
</Position27>
<Position28>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxdbgrid.pas"/>
<Caret Line="2724" Column="22" TopLine="2689"/>
<Filename Value="/usr/local/share/lazarus/lcl/dbgrids.pas"/>
<Caret Line="607" Column="10" TopLine="586"/>
</Position28>
<Position29>
<Filename Value="rxdbgridmainunit.pas"/>
<Caret Line="18" Column="21" TopLine="67"/>
</Position29>
<Position30>
<Filename Value="/usr/local/share/lazarus/components/rxnew/rxsortmemds.pas"/>
<Caret Line="1" Column="1" TopLine="34"/>
</Position30>
</JumpHistory>
</ProjectOptions>
<CompilerOptions>
@ -856,25 +880,16 @@
</Other>
</CompilerOptions>
<Debugging>
<Watches Count="6">
<Watches Count="3">
<Item1>
<Expression Value="rxTit.FCaption"/>
<Expression Value="aState"/>
</Item1>
<Item2>
<Expression Value="H"/>
<Expression Value="S1"/>
</Item2>
<Item3>
<Expression Value="W"/>
</Item3>
<Item4>
<Expression Value="W1"/>
</Item4>
<Item5>
<Expression Value="S"/>
</Item5>
<Item6>
<Expression Value="H1"/>
</Item6>
</Item3>
</Watches>
<Exceptions Count="1">
<Item1>

View File

@ -1,7 +1,7 @@
object RxDBGridMainForm: TRxDBGridMainForm
Left = 296
Left = 144
Height = 721
Top = 115
Top = 149
Width = 1187
ActiveControl = Panel1
Caption = 'RxDBGrid Demo'
@ -444,8 +444,6 @@ object RxDBGridMainForm: TRxDBGridMainForm
Precision = 0
Size = 15
end>
OnFilterRecord = RxMemoryData1FilterRecordEx
OnFilterRecordEx = RxMemoryData1FilterRecordEx
PacketRecords = 0
left = 152
top = 264

View File

@ -7,7 +7,7 @@ interface
uses
Classes, SysUtils, LResources, Forms, Controls, Graphics, Dialogs, rxmemds,
DB, rxdbgrid, RxAboutDialog, ExtCtrls, Buttons, Menus, ActnList, StdCtrls,
DBGrids, XMLPropStorage;
DBGrids, XMLPropStorage, types;
type
@ -73,8 +73,6 @@ type
procedure FormCreate(Sender: TObject);
procedure hlpAboutExecute(Sender: TObject);
procedure RxDBGrid1Filtred(Sender: TObject);
procedure RxMemoryData1FilterRecordEx(DataSet: TDataSet; var Accept: Boolean
);
procedure showColumnsDialogExecute(Sender: TObject);
procedure showFindDialogExecute(Sender: TObject);
procedure sysExitExecute(Sender: TObject);
@ -151,23 +149,6 @@ begin
end;
procedure TRxDBGridMainForm.RxMemoryData1FilterRecordEx(DataSet: TDataSet;
var Accept: Boolean);
var
i:integer;
begin
Accept:=true;
for i:=0 to RxDBGrid1.Columns.Count-1 do
begin
with TRxColumn(RxDBGrid1.Columns[i]) do
if (Filter.Value<>'') and (Filter.Value<>Field.AsString) then
begin
Accept:=false;
exit;
end;
end;
end;
procedure TRxDBGridMainForm.showColumnsDialogExecute(Sender: TObject);
begin
RxDBGrid1.ShowColumnsDialog;

View File

@ -526,7 +526,7 @@ type
procedure OutCaptionCellText90(aCol, aRow: integer; const aRect: TRect;
aState: TGridDrawState; const ACaption: string;
const TextOrient: TTextOrientation);
procedure OutCaptionSortMarker(const aRect: TRect; ASortMarker: TSortMarker);
procedure OutCaptionSortMarker(const aRect: TRect; ASortMarker: TSortMarker; ASortPosition:integer);
procedure OutCaptionMLCellText(aCol, aRow: integer; aRect: TRect;
aState: TGridDrawState; MLI: TMLCaptionItem);
procedure UpdateJMenuStates;
@ -1451,7 +1451,8 @@ end;
procedure TRxDBGrid.RestoreEditor;
begin
if EditorMode then begin
if EditorMode then
begin
EditorMode := False;
EditorMode := True;
end;
@ -2000,25 +2001,54 @@ begin
OutTextXY90(Canvas, aRect.Left + dY, aRect.Top + dw, ACaption, TextOrient);
end;
procedure TRxDBGrid.OutCaptionSortMarker(const aRect: TRect; ASortMarker: TSortMarker);
procedure TRxDBGrid.OutCaptionSortMarker(const aRect: TRect;
ASortMarker: TSortMarker; ASortPosition: integer);
var
X, Y: integer;
X, Y, W: integer;
S:string;
F:TFont;
begin
if (dgHeaderPushedLook in Options) then
begin
if (ASortMarker <> smNone) and (ASortPosition>0) then
begin
F:=TFont.Create;
F.Assign(Font);
if Font.Size = 0 then
Font.Size:=7
else
Font.Size:=Font.Size-2;
S:='('+IntToStr(ASortPosition)+')';
W:=Canvas.TextWidth(S) + 10;
end
else
begin
W:=6;
F:=nil;
end;
if ASortMarker = smDown then
begin
X := aRect.Right - FMarkerDown.Width - 6;
X := aRect.Right - FMarkerDown.Width - W;
Y := Trunc((aRect.Top + aRect.Bottom - FMarkerDown.Height) / 2);
Canvas.Draw(X, Y, FMarkerDown);
end
else
if ASortMarker = smUp then
begin
X := aRect.Right - FMarkerUp.Width - 6;
X := aRect.Right - FMarkerUp.Width - W;
Y := Trunc((aRect.Top + aRect.Bottom - FMarkerUp.Height) / 2);
Canvas.Draw(X, Y, FMarkerUp);
end;
if Assigned(F) then
begin
Canvas.TextOut( X + FMarkerDown.Width, Y, S);
Font.Assign(F);
FreeAndNil(F);
end;
end;
end;
@ -2247,6 +2277,9 @@ var
i:integer;
S:string;
Asc:array of boolean;
begin
FSortingNow:=true;
if FSortColumns.Count>1 then
begin
SetLength(Asc, FSortColumns.Count);
for i := 0 to FSortColumns.Count - 1 do
@ -2257,10 +2290,10 @@ begin
S:=S + FSortColumns[i].FieldName;
end;
{ TODO : Необходимо добавить опцию регистронезависимого поиска }
FSortingNow:=true;
FSortEngine.SortList(S, DataSource.DataSet, Asc, SortEngineOptions);
//FSortEngine.Sort(FSortColumns[0].Field, DataSource.DataSet, FSortColumns[0].FSortOrder = smUp, SortEngineOptions);
end
else
FSortEngine.Sort(FSortColumns[0].Field, DataSource.DataSet, FSortColumns[0].FSortOrder = smUp, SortEngineOptions);
FSortingNow:=false;
end;
@ -2283,6 +2316,8 @@ procedure TRxDBGrid.DefaultDrawTitle(aCol, aRow: integer; aRect: TRect;
var
ASortMarker: TSortMarker;
ASortPosition: integer;
Background: TColor;
i: integer;
Down: boolean;
@ -2316,12 +2351,14 @@ begin
Down := FPressed and (dgHeaderPushedLook in Options) and
(FPressedCol = GrdCol);
{
ASortMarker := smNone;
if (FSortField = GetFieldFromGridColumn(aCol)) then
ASortMarker := FSortOrder;}
if Assigned(GrdCol) then
ASortMarker := GrdCol.FSortOrder
begin
ASortMarker := GrdCol.FSortOrder;
if FSortColumns.Count>1 then
ASortPosition:=GrdCol.FSortPosition
else
ASortPosition:=-1;
end
else
ASortMarker := smNone;
@ -2367,11 +2404,15 @@ begin
aRect2.Bottom := aRect.Bottom;
aRect.Top := ARect2.Top;
if Down then
aState := aState + [gdPushed];
aState := aState + [gdPushed]
else
aState := aState - [gdPushed]
;
end
else
begin
aRect2.Bottom := aRect2.Top + MLI.Hegth * DefaultRowHeight;
aState := aState - [gdPushed];
end;
@ -2410,7 +2451,7 @@ begin
OutCaptionCellText(aCol, aRow, aRect, aState, GetDefaultColumnTitle(aCol));
end;
OutCaptionSortMarker(aRect, ASortMarker);
OutCaptionSortMarker(aRect, ASortMarker, ASortPosition+1);
end
else
begin
@ -3554,12 +3595,17 @@ begin
for i := 0 to Columns.Count - 1 do
begin
with TRxColumn(Columns[i]) do
if (Filter.Value <> '') and (Filter.Value <> Field.DisplayText) then
begin
if (Filter.Value <> '') then
begin
if (Filter.Value <> Field.DisplayText) then
begin
Accept := False;
break;
end;
end;
end;
end;
if Assigned(F_EventOnFilterRec) then
F_EventOnFilterRec(DataSet, Accept);
end;