• コメントのサイズを計測する

    Parameters

    • comment: {
          charSize: number;
          content: ({
              char: string;
              charWidth: number;
              count: number;
              font?: "defont" | "gulim" | "simsun";
              isButton?: boolean;
              type: "spacer";
          } | {
              content: string;
              font?: "defont" | "gulim" | "simsun";
              isButton?: boolean;
              slicedContent: string[];
              type: "text";
              width?: number[];
          })[];
          font: "defont" | "mincho" | "gothic" | "gulim" | "simsun";
          lineCount: number;
          lineHeight: number;
      }

      コメント

      • charSize: number
      • content: ({
            char: string;
            charWidth: number;
            count: number;
            font?: "defont" | "gulim" | "simsun";
            isButton?: boolean;
            type: "spacer";
        } | {
            content: string;
            font?: "defont" | "gulim" | "simsun";
            isButton?: boolean;
            slicedContent: string[];
            type: "text";
            width?: number[];
        })[]
      • font: "defont" | "mincho" | "gothic" | "gulim" | "simsun"
      • lineCount: number
      • lineHeight: number
    • renderer: IRenderer

      計測対象のレンダラーインスタンス

    Returns {
        height: number;
        itemWidth: number[][];
        lineWidth: number[];
        width: number;
    }

    計測結果

    • height: number
    • itemWidth: number[][]
    • lineWidth: number[]
    • width: number