Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
M
magicseteditor
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
MyCard
magicseteditor
Commits
fc6b0136
Commit
fc6b0136
authored
May 19, 2008
by
twanvl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed shrink(-overflow) for rotated fields
parent
2272ab26
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
4 deletions
+4
-4
src/data/field/text.cpp
src/data/field/text.cpp
+1
-1
src/util/rotation.cpp
src/util/rotation.cpp
+3
-3
No files found.
src/data/field/text.cpp
View file @
fc6b0136
...
@@ -58,7 +58,7 @@ TextStyle::TextStyle(const TextFieldP& field)
...
@@ -58,7 +58,7 @@ TextStyle::TextStyle(const TextFieldP& field)
double
TextStyle
::
getStretch
()
const
{
double
TextStyle
::
getStretch
()
const
{
if
(
content_width
>
0
&&
((
alignment
()
&
ALIGN_STRETCH
)
||
(
alignment
()
&
ALIGN_STRETCH_OVERFLOW
)))
{
if
(
content_width
>
0
&&
((
alignment
()
&
ALIGN_STRETCH
)
||
(
alignment
()
&
ALIGN_STRETCH_OVERFLOW
)))
{
double
factor
=
(
sideways
(
angle
)
?
double
(
height
)
:
width
-
padding_left
-
padding_right
)
/
content_width
;
double
factor
=
(
width
-
padding_left
-
padding_right
)
/
content_width
;
if
(
alignment
()
==
ALIGN_STRETCH
||
factor
<
1.0
)
{
if
(
alignment
()
==
ALIGN_STRETCH
||
factor
<
1.0
)
{
return
factor
;
return
factor
;
}
}
...
...
src/util/rotation.cpp
View file @
fc6b0136
...
@@ -135,9 +135,9 @@ wxRegion Rotation::trRectToRegion(const RealRect& r) const {
...
@@ -135,9 +135,9 @@ wxRegion Rotation::trRectToRegion(const RealRect& r) const {
RealPoint
Rotation
::
trInv
(
const
RealPoint
&
p
)
const
{
RealPoint
Rotation
::
trInv
(
const
RealPoint
&
p
)
const
{
double
a
=
deg_to_rad
(
angle
),
s
=
sin
(
a
),
c
=
cos
(
a
);
double
a
=
deg_to_rad
(
angle
),
s
=
sin
(
a
),
c
=
cos
(
a
);
double
x
=
(
p
.
x
-
origin
.
x
)
/
zoomX
,
y
=
(
p
.
y
-
origin
.
y
)
/
zoomY
;
double
x
=
p
.
x
-
origin
.
x
,
y
=
p
.
y
-
origin
.
y
;
return
RealPoint
(
c
*
x
-
s
*
y
,
return
RealPoint
(
(
c
*
x
-
s
*
y
)
/
zoomX
,
s
*
x
+
c
*
y
);
(
s
*
x
+
c
*
y
)
/
zoomY
);
}
}
RealPoint
Rotation
::
boundingBoxCorner
(
const
RealSize
&
size
)
const
{
RealPoint
Rotation
::
boundingBoxCorner
(
const
RealSize
&
size
)
const
{
...
...
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