Ticket #440 (closed defect: fixed)

Opened 5 years ago

Last modified 2 years ago

Missing [Script Info] header breaks reading/writing headers

Reported by: nielsm Owned by: nielsm
Priority: normal Milestone: 2.1.8
Component: Subtitle Version: 1.9
Severity: minor Keywords: confirmed
Cc: Platform: All
Sub Component:

Description

If the [Script Info] line is missing from a file, all properties that should be stored in that section are invisible to Aegisub, and no new can be written. For example, all the settings in the Properties dialog become useless.

While these files are technically malformed, they should still be handled in a sensible way. Probably also fixed when saved back to disk.

A fix might be, if no [Script Info] line has been found before the first non-comment non-blank line, insert one just before the first non-comment non-blank line and continue as usual.
While this still isn't VSFilter compatible (any kind of line can appear anywhere) it's still better.

Change History

comment:1 Changed 5 years ago by nielsm

  • Keywords confirmed added

comment:2 Changed 3 years ago by nielsm

  • Platform set to All
  • Version set to 1.9
  • Milestone set to 2.1.8

This has been around forever and we should just get it fixed.
How hard can it be?

comment:3 Changed 3 years ago by nielsm

  • Owner set to nielsm
  • Status changed from new to accepted

comment:4 Changed 3 years ago by nielsm

(In [3308]) Handle ASS files with missing [Script Info] header better, updates #440.
This should get some additional regression testing before the bug is closed and the fix backported to 2.1.8.

comment:5 Changed 2 years ago by nielsm

  • Status changed from accepted to closed
  • Resolution set to fixed

(In [3731]) Merge r3308, closes #440.

Note: See TracTickets for help on using tickets.