diff --git a/apps/documenteditor/main/app/template/ParagraphSettingsAdvanced.template b/apps/documenteditor/main/app/template/ParagraphSettingsAdvanced.template
index f14b20a0d..6dc19d04e 100644
--- a/apps/documenteditor/main/app/template/ParagraphSettingsAdvanced.template
+++ b/apps/documenteditor/main/app/template/ParagraphSettingsAdvanced.template
@@ -139,12 +139,15 @@
-
-
-
-
+
+
+
+
+
+
+
+
diff --git a/apps/documenteditor/main/app/view/ParagraphSettingsAdvanced.js b/apps/documenteditor/main/app/view/ParagraphSettingsAdvanced.js
index 00bef7748..dd0a1857b 100644
--- a/apps/documenteditor/main/app/view/ParagraphSettingsAdvanced.js
+++ b/apps/documenteditor/main/app/view/ParagraphSettingsAdvanced.js
@@ -42,7 +42,6 @@ define([ 'text!documenteditor/main/app/template/ParagraphSettingsAdvanced.tem
'common/main/lib/view/AdvancedSettingsWindow',
'common/main/lib/component/MetricSpinner',
'common/main/lib/component/CheckBox',
- 'common/main/lib/component/RadioBox',
'common/main/lib/component/ThemeColorPalette',
'common/main/lib/component/ColorButton',
'common/main/lib/component/ListView',
@@ -410,24 +409,35 @@ define([ 'text!documenteditor/main/app/template/ParagraphSettingsAdvanced.tem
this.listenTo(this.tabList.store, 'remove', storechanged);
this.listenTo(this.tabList.store, 'reset', storechanged);
- this.radioLeft = new Common.UI.RadioBox({
- el: $('#paragraphadv-radio-left'),
- labelText: this.textTabLeft,
- name: 'asc-radio-tab',
- checked: true
+ this.cmbAlign = new Common.UI.ComboBox({
+ el : $('#paraadv-cmb-align'),
+ style : 'width: 85px;',
+ menuStyle : 'min-width: 85px;',
+ editable : false,
+ cls : 'input-group-nr',
+ data : [
+ { value: 1, displayValue: this.textTabLeft },
+ { value: 3, displayValue: this.textTabCenter },
+ { value: 2, displayValue: this.textTabRight }
+ ]
});
+ this.cmbAlign.setValue(1);
- this.radioCenter = new Common.UI.RadioBox({
- el: $('#paragraphadv-radio-center'),
- labelText: this.textTabCenter,
- name: 'asc-radio-tab'
- });
-
- this.radioRight = new Common.UI.RadioBox({
- el: $('#paragraphadv-radio-right'),
- labelText: this.textTabRight,
- name: 'asc-radio-tab'
+ this.cmbLeader = new Common.UI.ComboBox({
+ el : $('#paraadv-cmb-leader'),
+ style : 'width: 85px;',
+ menuStyle : 'min-width: 85px;',
+ editable : false,
+ cls : 'input-group-nr',
+ data : [
+ { value: Asc.c_oAscTabLeader.None, displayValue: this.textNone },
+ { value: Asc.c_oAscTabLeader.Dot, displayValue: '....................' },
+ { value: Asc.c_oAscTabLeader.Hyphen, displayValue: '-----------------' },
+ { value: Asc.c_oAscTabLeader.MiddleDot, displayValue: '·················' },
+ { value: Asc.c_oAscTabLeader.Underscore,displayValue: '__________' }
+ ]
});
+ this.cmbLeader.setValue(Asc.c_oAscTabLeader.None);
this.btnAddTab = new Common.UI.Button({
el: $('#paraadv-button-add-tab')
@@ -562,7 +572,7 @@ define([ 'text!documenteditor/main/app/template/ParagraphSettingsAdvanced.tem
if (this._changedProps.get_Tabs()===null || this._changedProps.get_Tabs()===undefined)
this._changedProps.put_Tabs(new Asc.asc_CParagraphTabs());
this.tabList.store.each(function (item, index) {
- var tab = new Asc.asc_CParagraphTab(Common.Utils.Metric.fnRecalcToMM(item.get('tabPos')), item.get('tabAlign'));
+ var tab = new Asc.asc_CParagraphTab(Common.Utils.Metric.fnRecalcToMM(item.get('tabPos')), item.get('tabAlign'), item.get('tabLeader'));
this._changedProps.get_Tabs().add_Tab(tab);
}, this);
}
@@ -663,7 +673,8 @@ define([ 'text!documenteditor/main/app/template/ParagraphSettingsAdvanced.tem
rec.set({
tabPos: pos,
value: parseFloat(pos.toFixed(3)) + ' ' + Common.Utils.Metric.getCurrentMetricName(),
- tabAlign: tab.get_Value()
+ tabAlign: tab.get_Value(),
+ tabLeader: tab.asc_getLeader()
});
arr.push(rec);
}
@@ -1054,8 +1065,9 @@ define([ 'text!documenteditor/main/app/template/ParagraphSettingsAdvanced.tem
},
addTab: function(btn, eOpts){
- var val = this.numTab.getNumberValue();
- var align = this.radioLeft.getValue() ? 1 : (this.radioCenter.getValue() ? 3 : 2);
+ var val = this.numTab.getNumberValue(),
+ align = this.cmbAlign.getValue(),
+ leader = this.cmbLeader.getValue();
var store = this.tabList.store;
var rec = store.find(function(record){
@@ -1063,13 +1075,15 @@ define([ 'text!documenteditor/main/app/template/ParagraphSettingsAdvanced.tem
});
if (rec) {
rec.set('tabAlign', align);
+ rec.set('tabLeader', leader);
this._tabListChanged = true;
} else {
rec = new Common.UI.DataViewModel();
rec.set({
tabPos: val,
value: val + ' ' + Common.Utils.Metric.getCurrentMetricName(),
- tabAlign: align
+ tabAlign: align,
+ tabLeader: leader
});
store.add(rec);
}
@@ -1110,8 +1124,8 @@ define([ 'text!documenteditor/main/app/template/ParagraphSettingsAdvanced.tem
rawData = record;
}
this.numTab.setValue(rawData.tabPos);
- (rawData.tabAlign==1) ? this.radioLeft.setValue(true) : ((rawData.tabAlign==3) ? this.radioCenter.setValue(true) : this.radioRight.setValue(true));
-
+ this.cmbAlign.setValue(rawData.tabAlign);
+ this.cmbLeader.setValue(rawData.tabLeader);
},
hideTextOnlySettings: function(value) {
@@ -1173,6 +1187,8 @@ define([ 'text!documenteditor/main/app/template/ParagraphSettingsAdvanced.tem
tipNone: 'Set No Borders',
tipInner: 'Set Horizontal Inner Lines Only',
tipOuter: 'Set Outer Border Only',
- noTabs: 'The specified tabs will appear in this field'
+ noTabs: 'The specified tabs will appear in this field',
+ textLeader: 'Leader',
+ textNone: 'None'
}, DE.Views.ParagraphSettingsAdvanced || {}));
});
\ No newline at end of file
diff --git a/apps/documenteditor/main/locale/en.json b/apps/documenteditor/main/locale/en.json
index 71a60fb10..41ea11495 100644
--- a/apps/documenteditor/main/locale/en.json
+++ b/apps/documenteditor/main/locale/en.json
@@ -1357,6 +1357,8 @@
"DE.Views.ParagraphSettingsAdvanced.tipRight": "Set right border only",
"DE.Views.ParagraphSettingsAdvanced.tipTop": "Set top border only",
"DE.Views.ParagraphSettingsAdvanced.txtNoBorders": "No borders",
+ "DE.Views.ParagraphSettingsAdvanced.textLeader": "Leader",
+ "DE.Views.ParagraphSettingsAdvanced.textNone": "None",
"DE.Views.RightMenu.txtChartSettings": "Chart settings",
"DE.Views.RightMenu.txtHeaderFooterSettings": "Header and footer settings",
"DE.Views.RightMenu.txtImageSettings": "Image settings",