diff --git a/components/rx/Demos/RxDBGrid/RxDBGridDemo.lpi b/components/rx/Demos/RxDBGrid/RxDBGridDemo.lpi
index 339eccb4b..6e23543c7 100644
--- a/components/rx/Demos/RxDBGrid/RxDBGridDemo.lpi
+++ b/components/rx/Demos/RxDBGrid/RxDBGridDemo.lpi
@@ -21,7 +21,8 @@
-
+
+
@@ -57,9 +58,10 @@
+
-
+
@@ -67,11 +69,12 @@
+
-
+
@@ -79,27 +82,27 @@
-
+
-
+
-
+
-
+
@@ -110,73 +113,73 @@
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
@@ -186,75 +189,75 @@
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
@@ -263,49 +266,49 @@
-
+
-
+
-
+
-
+
-
+
-
+
-
-
-
+
+
+
@@ -316,21 +319,21 @@
-
+
-
+
-
+
@@ -340,7 +343,7 @@
-
+
@@ -350,37 +353,37 @@
-
+
-
+
-
+
-
+
-
-
-
+
+
+
@@ -388,21 +391,20 @@
-
+
-
-
-
-
+
+
+
-
+
-
+
@@ -411,14 +413,14 @@
-
+
-
+
@@ -428,7 +430,7 @@
-
+
@@ -438,7 +440,7 @@
-
+
@@ -446,27 +448,25 @@
-
+
-
+
-
+
-
-
-
+
@@ -474,7 +474,7 @@
-
+
@@ -484,7 +484,7 @@
-
+
@@ -494,7 +494,7 @@
-
+
@@ -503,7 +503,7 @@
-
+
@@ -513,7 +513,7 @@
-
+
@@ -522,135 +522,141 @@
-
+
+
-
-
-
+
+
+
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
+
-
+
-
+
+
+
+
+
diff --git a/components/rx/Demos/RxDBGrid/rxdbgridmainunit.lfm b/components/rx/Demos/RxDBGrid/rxdbgridmainunit.lfm
index 0529346cd..3daf092c2 100644
--- a/components/rx/Demos/RxDBGrid/rxdbgridmainunit.lfm
+++ b/components/rx/Demos/RxDBGrid/rxdbgridmainunit.lfm
@@ -151,7 +151,7 @@ object RxDBGridMainForm: TRxDBGridMainForm
end>
PropertyStorage = XMLPropStorage1
Version = 1
- OptionsRx = [rdgAllowColumnsForm, rdgAllowDialogFind, rdgDblClickOptimizeColWidth, rdgFooterRows, rdgAllowQuickSearch, rdgAllowToolMenu]
+ OptionsRx = [rdgAllowColumnsForm, rdgAllowDialogFind, rdgHighlightFocusCol, rdgHighlightFocusRow, rdgDblClickOptimizeColWidth, rdgFooterRows, rdgXORColSizing, rdgMultiTitleLines, rdgAllowQuickSearch, rdgAllowQuickFilter, rdgAllowFilterForm, rdgAllowSortForm, rdgAllowToolMenu]
FooterColor = clYellow
FooterRowCount = 1
OnFiltred = RxDBGrid1Filtred
@@ -165,6 +165,7 @@ object RxDBGridMainForm: TRxDBGridMainForm
PopupMenu = PopupMenu1
TabOrder = 0
TitleStyle = tsNative
+ UseXORFeatures = True
end
object Panel1: TPanel
Left = 0
diff --git a/components/rx/rxdbgrid.pas b/components/rx/rxdbgrid.pas
index cc5e66b77..8da91df88 100644
--- a/components/rx/rxdbgrid.pas
+++ b/components/rx/rxdbgrid.pas
@@ -1214,40 +1214,44 @@ begin
rxTit:=TRxColumnTitle(rxCol.Title);
H1:=0;
//Не забудем про вертикальную ориентацию
- if Assigned(rxCol) and rxCol.Visible then
+ if Assigned(rxCol) and rxCol.Visible and Assigned(rxTit) then
begin
- if rxTit.CaptionLinesCount > H then
- H:=rxTit.CaptionLinesCount;
- for j:=0 to rxTit.CaptionLinesCount-1 do
+ if rxTit.Orientation in [toVertical270, toVertical90] then
+ H1:=Max((tmpCanvas.TextWidth(Columns[i].Title.Caption)+ tmpCanvas.TextWidth('W')) div DefaultRowHeight, H)
+ else
begin
- MLRec1:=rxTit.CaptionLine(j);
- S:=MLRec1.Caption;
- if not Assigned(MLRec1.Prior) then
+ if rxTit.CaptionLinesCount > H then
+ H:=rxTit.CaptionLinesCount;
+ for j:=0 to rxTit.CaptionLinesCount-1 do
begin
- W:=rxCol.Width;//MLRec1.Width;
- P:=MLRec1.Next;
- while Assigned(P) do
+ MLRec1:=rxTit.CaptionLine(j);
+ S:=MLRec1.Caption;
+ if not Assigned(MLRec1.Prior) then
begin
- Inc(W, P.Col.Width);//P.Width);
- P:=P.Next;
- end;
- W1:=tmpCanvas.TextWidth(MLRec1.Caption)+2;
- if W1 > W then
- MLRec1.Hegth:= W1 div W + 1
- else
- MLRec1.Hegth:=1;
+ W:=rxCol.Width;//MLRec1.Width;
+ P:=MLRec1.Next;
+ while Assigned(P) do
+ begin
+ Inc(W, P.Col.Width);//P.Width);
+ P:=P.Next;
+ end;
+ W1:=tmpCanvas.TextWidth(MLRec1.Caption)+2;
+ if W1 > W then
+ MLRec1.Hegth:= W1 div W + 1
+ else
+ MLRec1.Hegth:=1;
- P:=MLRec1.Next;
- while Assigned(P) do
- begin
- P.Hegth:=MLRec1.Hegth;
- P:=P.Next;
+ P:=MLRec1.Next;
+ while Assigned(P) do
+ begin
+ P.Hegth:=MLRec1.Hegth;
+ P:=P.Next;
+ end;
end;
+ H1:=H1 + MLRec1.Hegth;
end;
- H1:=H1 + MLRec1.Hegth;
end;
end;
-
if H1 > H then
H:=H1;
end;