Exemple #1
0
 public static void writeASSStyle(AssFile file, String path, BufferedWriter out)
     throws IOException {
   out.write("[V4+ Styles]");
   for (String style : file.getStyle()) {
     out.write(style + "\n");
   }
 }
Exemple #2
0
  public static void writeASSText(AssFile file, String path, BufferedWriter out)
      throws IOException {

    out.write("[Events]\n");
    out.write("Format: Layer, Start, End, Style, Name, MarginL, MarginR, MarginV, Effect, Text\n");
    for (SubtitleLine sl : file.getLines()) {
      if (!sl.getCom()) {
        out.write("Dialogue: ");
      }
      out.write(sl.getL() + ",");
      out.write(sl.getDebut() + ",");
      out.write(sl.getFin() + ",");
      out.write(sl.getStyle() + ",");
      out.write(sl.getActeur() + ",");
      out.write(sl.getGauche() + ",");
      out.write(sl.getDroite() + ",");
      out.write(sl.getVertical() + ",");
      out.write(sl.getEffet() + ",");
      out.write(sl.getTexte() + "\n");
    }
    out.close();
  }
Exemple #3
0
  public static void writeASSInfo(AssFile file, String path, BufferedWriter out)
      throws IOException {

    out.write("[Script Info]\n");
    out.write("; Script generated by JavASS 0.1\n");
    out.write("; Quentin Van de kadsye\n");
    out.write("Title: " + file.getInfo().getTitre() + "\n");
    out.write("ScriptType: v4.00+\n");
    out.write("WrapStyle: " + file.getInfo().getWrapStyle() + "\n");
    out.write("ScaledBorderAndShadow: ");
    if (file.getInfo().getScale()) out.write("yes\n");
    else out.write("no\n");
    out.write("YCbCr Matrix: " + file.getInfo().getYCbCr() + "\n");
    out.write("Original Script: " + file.getInfo().getOriginalScript() + "\n");
    out.write("Original Translation: " + file.getInfo().getTraduction() + "\n");
    out.write("Original Editing: " + file.getInfo().getEdition() + "\n");
    out.write("Original Timing: " + file.getInfo().getTiming() + "\n");
    out.write("Synch Point: " + file.getInfo().getSynch() + "\n");
    out.write("Script Updated By: " + file.getInfo().getUpdatedBy() + "\n");
    out.write("Update Details: " + file.getInfo().getUpdateDetails() + "\n");
    out.write("PlayResX: " + file.getInfo().getResX() + "\n");
    out.write("PlayResY: " + file.getInfo().getResY() + "\n");
    out.write("\n");
    out.write("[Aegisub Project Garbage]");
    out.write("\n");
  }