Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
ae394876
Kaydet (Commit)
ae394876
authored
Şub 04, 2014
tarafından
Miklos Vajna
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
swpagerelsize ui: implement remaining height support
Change-Id: Ia603c4ac6c8e9e049473904203d2c471f03ce8a5
üst
a90374fc
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
65 additions
and
18 deletions
+65
-18
frmpage.cxx
sw/source/ui/frmdlg/frmpage.cxx
+22
-0
frmpage.hxx
sw/source/ui/inc/frmpage.hxx
+1
-0
frmtypepage.ui
sw/uiconfig/swriter/ui/frmtypepage.ui
+42
-18
No files found.
sw/source/ui/frmdlg/frmpage.cxx
Dosyayı görüntüle @
ae394876
...
...
@@ -649,6 +649,7 @@ SwFrmPage::SwFrmPage(Window *pParent, const SfxItemSet &rSet)
get
(
m_pHeightAutoFT
,
"autoheightft"
);
m_aHeightED
.
set
(
get
<
MetricField
>
(
"height"
));
get
(
m_pRelHeightCB
,
"relheight"
);
get
(
m_pRelHeightRelationLB
,
"relheightrelation"
);
get
(
m_pAutoHeightCB
,
"autoheight"
);
get
(
m_pFixedRatioCB
,
"ratio"
);
...
...
@@ -823,6 +824,7 @@ void SwFrmPage::setOptimalRelWidth()
m_pHoriRelationLB
->
set_width_request
(
aBiggest
.
Width
());
m_pVertRelationLB
->
set_width_request
(
aBiggest
.
Width
());
m_pRelWidthRelationLB
->
set_width_request
(
aBiggest
.
Width
());
m_pRelHeightRelationLB
->
set_width_request
(
aBiggest
.
Width
());
m_pHoriRelationLB
->
Clear
();
}
...
...
@@ -954,12 +956,18 @@ void SwFrmPage::Reset( const SfxItemSet &rSet )
else
m_pRelWidthRelationLB
->
Disable
();
m_pRelHeightRelationLB
->
InsertEntry
(
aFramePosString
.
GetString
(
SwFPos
::
FRAME
));
m_pRelHeightRelationLB
->
InsertEntry
(
aFramePosString
.
GetString
(
SwFPos
::
REL_PG_FRAME
));
if
(
rFrmSize
.
GetHeightPercent
()
!=
0xff
&&
rFrmSize
.
GetHeightPercent
()
!=
0
)
{
//calculate the rerference value from the with and relative width values
sal_Int32
nSpace
=
rFrmSize
.
GetHeight
()
*
100
/
rFrmSize
.
GetHeightPercent
();
m_aHeightED
.
SetRefValue
(
nSpace
);
m_pRelHeightRelationLB
->
Enable
();
}
else
m_pRelHeightRelationLB
->
Disable
();
// general initialisation part
switch
(
rAnchor
.
GetAnchorId
())
...
...
@@ -1152,6 +1160,14 @@ sal_Bool SwFrmPage::FillItemSet(SfxItemSet &rSet)
else
if
(
nRelWidthRelation
==
1
)
aSz
.
SetWidthPercentRelation
(
text
::
RelOrientation
::
PAGE_FRAME
);
}
sal_uInt16
nRelHeightRelation
=
m_pRelHeightRelationLB
->
GetSelectEntryPos
();
if
(
nRelHeightRelation
!=
LISTBOX_ENTRY_NOTFOUND
)
{
if
(
nRelHeightRelation
==
0
)
aSz
.
SetHeightPercentRelation
(
text
::
RelOrientation
::
FRAME
);
else
if
(
nRelHeightRelation
==
1
)
aSz
.
SetHeightPercentRelation
(
text
::
RelOrientation
::
PAGE_FRAME
);
}
bool
bValueModified
=
(
m_aWidthED
.
IsValueModified
()
||
m_aHeightED
.
IsValueModified
());
bool
bCheckChanged
=
(
m_pRelWidthCB
->
GetSavedValue
()
!=
m_pRelWidthCB
->
IsChecked
()
...
...
@@ -1743,6 +1759,7 @@ IMPL_LINK( SwFrmPage, RelSizeClickHdl, CheckBox *, pBtn )
else
// pBtn == m_pRelHeightCB
{
m_aHeightED
.
ShowPercent
(
pBtn
->
IsChecked
());
m_pRelHeightRelationLB
->
Enable
(
pBtn
->
IsChecked
());
if
(
pBtn
->
IsChecked
())
m_aHeightED
.
get
()
->
SetMax
(
MAX_PERCENT_HEIGHT
);
}
...
...
@@ -2331,6 +2348,11 @@ void SwFrmPage::Init(const SfxItemSet& rSet, sal_Bool bReset)
m_pRelWidthRelationLB
->
SelectEntryPos
(
1
);
else
m_pRelWidthRelationLB
->
SelectEntryPos
(
0
);
if
(
rSize
.
GetHeightPercentRelation
()
==
text
::
RelOrientation
::
PAGE_FRAME
)
m_pRelHeightRelationLB
->
SelectEntryPos
(
1
);
else
m_pRelHeightRelationLB
->
SelectEntryPos
(
0
);
}
sal_uInt16
*
SwFrmPage
::
GetRanges
()
...
...
sw/source/ui/inc/frmpage.hxx
Dosyayı görüntüle @
ae394876
...
...
@@ -55,6 +55,7 @@ class SwFrmPage: public SfxTabPage
FixedText
*
m_pHeightAutoFT
;
PercentField
m_aHeightED
;
CheckBox
*
m_pRelHeightCB
;
ListBox
*
m_pRelHeightRelationLB
;
CheckBox
*
m_pAutoHeightCB
;
CheckBox
*
m_pFixedRatioCB
;
...
...
sw/uiconfig/swriter/ui/frmtypepage.ui
Dosyayı görüntüle @
ae394876
...
...
@@ -205,24 +205,6 @@
<property
name=
"height"
>
1
</property>
</packing>
</child>
<child>
<object
class=
"GtkCheckButton"
id=
"relheight"
>
<property
name=
"label"
translatable=
"yes"
>
Re_lative
</property>
<property
name=
"visible"
>
True
</property>
<property
name=
"can_focus"
>
True
</property>
<property
name=
"receives_default"
>
False
</property>
<property
name=
"margin_left"
>
12
</property>
<property
name=
"use_underline"
>
True
</property>
<property
name=
"xalign"
>
0
</property>
<property
name=
"draw_indicator"
>
True
</property>
</object>
<packing>
<property
name=
"left_attach"
>
0
</property>
<property
name=
"top_attach"
>
1
</property>
<property
name=
"width"
>
2
</property>
<property
name=
"height"
>
1
</property>
</packing>
</child>
<child>
<object
class=
"GtkCheckButton"
id=
"autoheight"
>
<property
name=
"label"
translatable=
"yes"
>
AutoSize
</property>
...
...
@@ -286,6 +268,48 @@
<property
name=
"height"
>
1
</property>
</packing>
</child>
<child>
<object
class=
"GtkBox"
id=
"box2"
>
<property
name=
"visible"
>
True
</property>
<property
name=
"can_focus"
>
False
</property>
<property
name=
"spacing"
>
6
</property>
<child>
<object
class=
"GtkCheckButton"
id=
"relheight"
>
<property
name=
"label"
translatable=
"yes"
>
Re_lative from
</property>
<property
name=
"visible"
>
True
</property>
<property
name=
"can_focus"
>
True
</property>
<property
name=
"receives_default"
>
False
</property>
<property
name=
"margin_left"
>
12
</property>
<property
name=
"use_underline"
>
True
</property>
<property
name=
"xalign"
>
0
</property>
<property
name=
"draw_indicator"
>
True
</property>
</object>
<packing>
<property
name=
"expand"
>
False
</property>
<property
name=
"fill"
>
True
</property>
<property
name=
"position"
>
0
</property>
</packing>
</child>
<child>
<object
class=
"GtkComboBoxText"
id=
"relheightrelation"
>
<property
name=
"visible"
>
True
</property>
<property
name=
"can_focus"
>
False
</property>
<property
name=
"hexpand"
>
True
</property>
</object>
<packing>
<property
name=
"expand"
>
False
</property>
<property
name=
"fill"
>
True
</property>
<property
name=
"position"
>
1
</property>
</packing>
</child>
</object>
<packing>
<property
name=
"left_attach"
>
0
</property>
<property
name=
"top_attach"
>
1
</property>
<property
name=
"width"
>
2
</property>
<property
name=
"height"
>
1
</property>
</packing>
</child>
</object>
<packing>
<property
name=
"left_attach"
>
0
</property>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment