Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
sdkjs
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boris Kocherov
sdkjs
Commits
fc5e6450
Commit
fc5e6450
authored
Apr 25, 2016
by
Alexander.Trofimov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Flush Text Measurer
parent
ece15bba
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
11 deletions
+16
-11
cell/native/native.js
cell/native/native.js
+1
-9
common/Native/Wrappers/TextMeasurerWrapper.js
common/Native/Wrappers/TextMeasurerWrapper.js
+15
-2
No files found.
cell/native/native.js
View file @
fc5e6450
...
...
@@ -5711,15 +5711,7 @@ function OfflineEditor () {
this
.
offline_afteInit
=
function
()
{
window
.
AscAlwaysSaveAspectOnResizeTrack
=
true
;};
this
.
flushTextMeasurer
=
function
()
{
AscCommon
.
g_oTextMeasurer
.
m_oFont
=
null
;
AscCommon
.
g_oTextMeasurer
.
m_oTextPr
=
null
;
AscCommon
.
g_oTextMeasurer
.
m_oGrFonts
=
new
CGrRFonts
();
AscCommon
.
g_oTextMeasurer
.
m_oLastFont
=
new
CFontSetup
();
AscCommon
.
g_oTextMeasurer
.
LastFontOriginInfo
=
{
Name
:
""
,
Replace
:
null
};
AscCommon
.
g_oTextMeasurer
.
Ascender
=
0
;
AscCommon
.
g_oTextMeasurer
.
Descender
=
0
;
AscCommon
.
g_oTextMeasurer
.
Height
=
0
;
AscCommon
.
g_oTextMeasurer
.
UnitsPerEm
=
0
;
AscCommon
.
g_oTextMeasurer
.
Flush
();
};
}
var
_s
=
new
OfflineEditor
();
...
...
common/Native/Wrappers/TextMeasurerWrapper.js
View file @
fc5e6450
...
...
@@ -16,7 +16,7 @@ function CTextMeasurerWrapper()
this
.
Descender
=
0
;
this
.
Height
=
0
;
this
.
UnitsPerEm
=
0
;
}
;
}
CTextMeasurerWrapper
.
prototype
=
{
...
...
@@ -221,6 +221,19 @@ CTextMeasurerWrapper.prototype =
GetHeight
:
function
()
{
return
this
.
Height
;
},
Flush
:
function
()
{
this
.
m_oFont
=
null
;
this
.
m_oTextPr
=
null
;
this
.
m_oGrFonts
=
new
CGrRFonts
();
this
.
m_oLastFont
=
new
CFontSetup
();
this
.
LastFontOriginInfo
=
{
Name
:
""
,
Replace
:
null
};
this
.
Ascender
=
0
;
this
.
Descender
=
0
;
this
.
Height
=
0
;
this
.
UnitsPerEm
=
0
;
}
};
...
...
@@ -367,7 +380,7 @@ function GetLoadInfoForMeasurer(info, lStyle)
SrcBold
:
bSrcBold
,
SrcItalic
:
bSrcItalic
};
}
;
}
CTextMeasurerWrapper
.
prototype
[
"
Init
"
]
=
CTextMeasurerWrapper
.
prototype
.
Init
;
...
...
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