When I changed the paragraph tag to 0x21b5 (that is, changes ¶ to↵), the paragraph tag didn't draw or was drawn as a square
CRunParagraphMark.prototype.Measure = function(oMeasurer, oTextPr, isEndCell)
{
this.private_UpdateMarkType(isEndCell ? FLAGS_MARK_ENDCELL : FLAGS_MARK_NORMAL);
let nUnicode = 0x21b5; // isEndCell ? 0x00A4 : 0x00B6;
let nFontSlot = oTextPr.RTL || oTextPr.CS ? AscWord.fontslot_CS : AscWord.fontslot_ASCII;
let oFontInfo = oTextPr.GetFontInfo(nFontSlot);
this.Grapheme = oMeasurer.GetGraphemeByUnicode(nUnicode, oFontInfo.Name, oFontInfo.Style);
let nFontSize = oFontInfo.Size;
if (oTextPr.VertAlign !== AscCommon.vertalign_Baseline)
nFontSize = AscWord.AlignFontSize(nFontSize, AscCommon.vaKSize);
this.Flags = (this.Flags & 0xFFFF) | (((nFontSize * 64) & 0xFFFF) << 16);
this.Width = 0;
this.WidthVisible = ((AscFonts.GetGraphemeWidth(this.Grapheme) * nFontSize) * AscWord.TEXTWIDTH_DIVIDER) | 0;
};
like this, the paragraph mask drawing
Hello @parkavenue1990
Could you please elaborate how and where did you exactly change it?
Hello! I’m using documenteditor, like this:
When i select “Home → Nonprinting characters”
the paragraph end is ¶, and i want change “¶” to “↵”.
I locally modify the code that ParagraphMark.js, about line 80. Paragraph tag drawing problem after modification (sometimes normal display, sometimes no display or display blocks)
code:
CRunParagraphMark.prototype.Measure = function(oMeasurer, oTextPr, isEndCell)
{
this.private_UpdateMarkType(isEndCell ? FLAGS_MARK_ENDCELL : FLAGS_MARK_NORMAL);
// this is my modify, change 0x00B6 to 0x21B5(¶ to ↵)
let nUnicode = 0x21B5; // isEndCell ? 0x00A4 : 0x00B6;
let nFontSlot = oTextPr.RTL || oTextPr.CS ? AscWord.fontslot_CS : AscWord.fontslot_ASCII;
let oFontInfo = oTextPr.GetFontInfo(nFontSlot);
this.Grapheme = oMeasurer.GetGraphemeByUnicode(nUnicode, oFontInfo.Name, oFontInfo.Style);
let nFontSize = oFontInfo.Size;
if (oTextPr.VertAlign !== AscCommon.vertalign_Baseline)
nFontSize = AscWord.AlignFontSize(nFontSize, AscCommon.vaKSize);
this.Flags = (this.Flags & 0xFFFF) | (((nFontSize * 64) & 0xFFFF) << 16);
this.Width = 0;
this.WidthVisible = ((AscFonts.GetGraphemeWidth(this.Grapheme) * nFontSize) * AscWord.TEXTWIDTH_DIVIDER) | 0;
};
I want to know how to change the paragraph tag through the code ,Thank you
Hello @parkavenue1990
Unfortunately, this symbol cannot be changed.