| 
UID2积分8682帖子2905主题199论坛币13044 威望16 EP值2349 MP值15 阅读权限200注册时间2011-8-3在线时间2597 小时最后登录2024-8-28
 
   
 | 
| To add the support of multiple ASS style and avoiding the modification of the TCC file, we can use the inherited ASS header, see http://www.tcax.org/forum.php?mod=viewthread&tid=54. 
 And to ease the access to the values stored in the ASS header string, we need a wrapper class named AssStyles which is a container of AssStyle objects.
 
 
 Implementation Tips
 
 1. styles = AssStyles(GetVal(val_AssHeader)), the constructor extracts the information in the ASS Header string and store them in the AssStyles class instance.
 2. The AssStyles class has a dict to hold the AssStyle objects, style = styles['style_name']
 3. we can then access to the style values by style.name, style.fs, etc.
 
 
 
 
 | 
 |