class Window_Help < Window_Base
 #06/09/23
  #--------------------------------------------------------------------------
  # ● テキスト設定
  #     text  : ウィンドウに表示する文字列
  #     align : アラインメント (0..左揃え、1..中央揃え、2..右揃え)
  #--------------------------------------------------------------------------
  def set_text(text, align = 0)
    # テキストとアラインメントの少なくとも一方が前回と違っている場合
    if text != @text or align != @align
      # テキストを再描画
      self.contents.clear
      if self.width - 40 < self.contents.text_size(text).width
        b = ""
        c = text.scan(/./)
        for i in c
          text = b
          if self.width - 40 < self.contents.text_size(b += i).width
            break
          end
        end
        if @text != text
          p "文字数が多くてウィンドウからはみ出すよ！"
        end
      end
      self.contents.font.color = normal_color
      self.contents.draw_text(4, 0, self.width - 40, 32, text, align)
      @text = text
      @align = align
      @actor = nil
    end
    self.visible = true
  end
end