Skip to content

[BUG] Rendering corruption in .bat files when a single line exceeds a specific character length #17864

@kartriderking

Description

@kartriderking

Is there an existing issue for this?

  • I have searched the existing issues

Is the issue reproducible in Notepad++ without plugin?

  • I have tried Notepad++ without plugin

Is the issue reproducible in portable version of Notepad++?

  • I have tried portable version of Notepad++

Does the issue affect SciTE?

  • I have tried SciTE

Description of the Issue

I am reporting a rendering bug encountered when editing files with a extension .bat. When a single line of text reaches a certain length threshold, the display begins to render incorrectly, as shown in the screenshot below.

The Chinese character '机' incorrectly renders as its UTF-8 hex representation: \xE6 \x9C \xBA.

Image

Key Observations:
Scope: This issue appears to be specific to the file extension..bat

Comparison: When the same content is saved with other file extensions (e.g. .txt), the text renders normally.

Steps To Reproduce

  1. input the following code:
    python .\fetch.py "159915.SZ,588000.SH,159601.SZ,510050.SH,510330.SH,512500.SH,159845.SZ,159532.SZ,159628.SZ,159949.SZ,159967.SZ,159901.SZ,588030.SH,515180.SH,515450.SH,512040.SH,159758.SZ" "创业板ETF易方达,科创50ETF,A50ETF,上证50ETF,沪深300ETF华夏,中证500ETF华夏,中证1000ETF,中证2000ETF易方达,国证2000ETF万家,创业板50ETF,创业板成长ETF,深证100ETF易方达,科创100ETF博时,红利ETF易方达,红利低波50ETF,价值100ETF,红利质量ETF" "price_data.csv"
    python .\fetch.py "159611.SZ,159667.SZ,159735.SZ,159745.SZ,159766.SZ,159843.SZ,159851.SZ,159852.SZ,159855.SZ,159883.SZ,159995.SZ,159996.SZ,159997.SZ,159998.SZ,162411.SZ,159647.SZ,159786.SZ,512170.SH,512400.SH,512690.SH,512800.SH,512880.SH,512980.SH,513090.SH,513180.SH,513400.SH,513860.SH,515030.SH,515050.SH,515210.SH,515220.SH,515250.SH,516110.SH,516150.SH,516670.SH,516970.SH,560280.SH,562800.SH,501312.SH,512200.SH,512600.SH,512660.SH,513060.SH,513100.SH,515790.SH,515950.SH,516020.SH,516560.SH,516770.SH,516910.SH,562500.SH,159515.SZ" "电力,工业母机,港股消费,建材,旅游,食品饮料,金融科技,软件,影视,医疗器械,芯片,家电,电子,计算机,华宝油气,中药,vr,医疗,有色金属,酒,银行,券商,传媒,香港证券,恒生科技,道琼斯,港股通科技,新能源车,通信,钢铁,煤炭,智能汽车,汽车,稀土,畜牧养殖,基建工程,工程机械,稀有金属,海外科技,房地产,消费,军工,恒生医疗,纳斯达克,光伏,医药龙头,化工,养老,游戏动漫,物流,机器人,恒生生物科技" "price_data_ind.csv"
    python .\cal.py price_data.csv
    python .\cal.py price_data_ind.csv
    pause
  2. save as test.bat

Current Behavior

Display text abnormally

Expected Behavior

Display text normally

Debug Information

 

Anything else?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    scintilla dependentCan't be considered for N++ implementation unless/until Scintilla changes

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions