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
605900ae
Commit
605900ae
authored
Jun 06, 2016
by
alexey.musinov
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'develop' of
https://github.com/ONLYOFFICE/sdkjs
into develop
parents
73b87387
f2f6dded
Changes
8
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
401 additions
and
187 deletions
+401
-187
common/plugins.js
common/plugins.js
+27
-1
word/Editor/Document.js
word/Editor/Document.js
+17
-2
word/Editor/FootEndNote.js
word/Editor/FootEndNote.js
+1
-1
word/Editor/Footnotes.js
word/Editor/Footnotes.js
+69
-69
word/Editor/Paragraph.js
word/Editor/Paragraph.js
+2
-0
word/Editor/ParagraphContent.js
word/Editor/ParagraphContent.js
+267
-113
word/Editor/Paragraph_Recalculate.js
word/Editor/Paragraph_Recalculate.js
+1
-1
word/Editor/Run.js
word/Editor/Run.js
+17
-0
No files found.
common/plugins.js
View file @
605900ae
...
...
@@ -611,6 +611,32 @@ function TEST_PLUGINS()
"
buttons
"
:
[]
}
]
},
{
"
name
"
:
"
clipart
"
,
"
guid
"
:
"
asc.{F5BACB61-64C5-4711-AC8A-D01EC3B2B6F1}
"
,
"
variations
"
:
[
{
"
description
"
:
"
clipart
"
,
"
url
"
:
"
clipart/index.html
"
,
"
icons
"
:
[
"
clipart/icon.png
"
,
"
clipart/icon@2x.png
"
],
"
isViewer
"
:
true
,
"
EditorsSupport
"
:
[
"
word
"
],
"
isVisual
"
:
true
,
"
isModal
"
:
false
,
"
isInsideMode
"
:
false
,
"
initDataType
"
:
"
none
"
,
"
initData
"
:
""
,
"
isUpdateOleOnResize
"
:
false
,
"
buttons
"
:
[
{
"
text
"
:
"
Ok
"
,
"
primary
"
:
true
}
]
}
]
}
];
...
...
word/Editor/Document.js
View file @
605900ae
...
...
@@ -4503,6 +4503,9 @@ CDocument.prototype.Paragraph_Add = function(ParaItem, bRecalculate
case
para_PageNum
:
case
para_Field
:
case
para_FootnoteReference
:
case
para_FootnoteRef
:
case
para_Separator
:
case
para_ContinuationSeparator
:
{
// Если у нас что-то заселекчено и мы вводим текст или пробел
// и т.д., тогда сначала удаляем весь селект.
...
...
@@ -11517,6 +11520,18 @@ CDocument.prototype.OnKeyDown = function(e)
// this.Paragraph_Add(new ParaFootnoteReference(oFootnote));
// bRetValue = keydownresult_PreventAll;
// }
// else if (114 === e.KeyCode)
// {
// this.History.Create_NewPoint();
// this.Paragraph_Add(new ParaSeparator());
// bRetValue = keydownresult_PreventAll;
// }
// else if (115 === e.KeyCode)
// {
// this.History.Create_NewPoint();
// this.Paragraph_Add(new ParaContinuationSeparator());
// bRetValue = keydownresult_PreventAll;
// }
// TEST <--
else
if
(
e
.
KeyCode
==
121
&&
true
===
e
.
ShiftKey
)
// Shift + F10 - контекстное меню
{
...
...
word/Editor/FootEndNote.js
View file @
605900ae
word/Editor/Footnotes.js
View file @
605900ae
...
...
@@ -20,6 +20,7 @@ function CFootnotesController(LogicDocument)
this
.
Footnote
=
{};
// Список всех сносок с ключом - Id.
this
.
Pages
=
[];
// Добавляем данный класс в таблицу Id (обязательно в конце конструктора)
LogicDocument
.
Get_TableId
().
Add
(
this
,
this
.
Id
);
}
...
...
@@ -65,7 +66,6 @@ CFootnotesController.prototype.Recalculate = function(nPageIndex, X, XLimit, Y,
// Мы пересчет начинаем с 0, потом просто делаем сдвиг, через функцию Shift.
var
CurY
=
Y
;
for
(
var
nIndex
=
0
;
nIndex
<
this
.
Pages
[
nPageIndex
].
Elements
.
length
;
++
nIndex
)
{
var
Footnote
=
this
.
Pages
[
nPageIndex
].
Elements
[
nIndex
];
...
...
word/Editor/Paragraph.js
View file @
605900ae
...
...
@@ -3030,6 +3030,8 @@ Paragraph.prototype =
case
para_NewLine
:
case
para_FootnoteReference
:
case
para_FootnoteRef
:
case
para_Separator
:
case
para_ContinuationSeparator
:
default
:
{
// Элементы данного типа добавляем во внутренний элемент
...
...
word/Editor/ParagraphContent.js
View file @
605900ae
This diff is collapsed.
Click to expand it.
word/Editor/Paragraph_Recalculate.js
View file @
605900ae
...
...
@@ -717,7 +717,7 @@ Paragraph.prototype.private_RecalculatePageXY = function(CurLine, CurPa
PRS
.
YLimit
=
YLimit
;
PRS
.
Y
=
YStart
;
this
.
Pages
.
length
=
CurPage
+
1
this
.
Pages
.
length
=
CurPage
+
1
;
this
.
Pages
[
CurPage
]
=
new
CParaPage
(
XStart
,
YStart
,
XLimit
,
YLimit
,
CurLine
);
};
...
...
word/Editor/Run.js
View file @
605900ae
...
...
@@ -2251,10 +2251,15 @@ ParaRun.prototype.Recalculate_Range = function(PRS, ParaPr, Depth)
case
para_Text
:
case
para_FootnoteReference
:
case
para_FootnoteRef
:
case
para_Separator
:
case
para_ContinuationSeparator
:
{
// Отмечаем, что началось слово
StartWord
=
true
;
if
(
para_ContinuationSeparator
===
ItemType
)
Item
.
Update_Width
(
PRS
);
// При проверке, убирается ли слово, мы должны учитывать ширину предшествующих пробелов.
var
LetterLen
=
Item
.
Width
/
TEXTWIDTH_DIVIDER
;
//var LetterLen = Item.Get_Width();
...
...
@@ -3098,6 +3103,8 @@ ParaRun.prototype.Recalculate_LineMetrics = function(PRS, ParaPr, _CurLine, _Cur
case
para_PageNum
:
case
para_FootnoteReference
:
case
para_FootnoteRef
:
case
para_Separator
:
case
para_ContinuationSeparator
:
{
UpdateLineMetricsText
=
true
;
break
;
...
...
@@ -3197,6 +3204,8 @@ ParaRun.prototype.Recalculate_Range_Width = function(PRSC, _CurLine, _CurRange)
case
para_Text
:
case
para_FootnoteReference
:
case
para_FootnoteRef
:
case
para_Separator
:
case
para_ContinuationSeparator
:
{
PRSC
.
Letters
++
;
...
...
@@ -3349,6 +3358,8 @@ ParaRun.prototype.Recalculate_Range_Spaces = function(PRSA, _CurLine, _CurRange,
case
para_Text
:
case
para_FootnoteReference
:
case
para_FootnoteRef
:
case
para_Separator
:
case
para_ContinuationSeparator
:
{
var
WidthVisible
=
0
;
...
...
@@ -4248,6 +4259,8 @@ ParaRun.prototype.Draw_HighLights = function(PDSH)
case
para_Sym
:
case
para_FootnoteReference
:
case
para_FootnoteRef
:
case
para_Separator
:
case
para_ContinuationSeparator
:
{
if
(
para_Drawing
===
ItemType
&&
!
Item
.
Is_Inline
()
)
break
;
...
...
@@ -4439,6 +4452,8 @@ ParaRun.prototype.Draw_Elements = function(PDSE)
case
para_Sym
:
case
para_FootnoteReference
:
case
para_FootnoteRef
:
case
para_Separator
:
case
para_ContinuationSeparator
:
{
if
(
para_Tab
===
ItemType
)
{
...
...
@@ -4711,6 +4726,8 @@ ParaRun.prototype.Draw_Lines = function(PDSL)
case
para_Sym
:
case
para_FootnoteReference
:
case
para_FootnoteRef
:
case
para_Separator
:
case
para_ContinuationSeparator
:
{
if
(
para_Drawing
!=
ItemType
||
Item
.
Is_Inline
()
)
{
...
...
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