using System;
using System.Windows.Forms;
using FooEditor.Plugin;
using FooEditEngine.Windows;

namespace FooEditor
{
    class PrintHFParser
    {
        EditForm target;
        public PrintHFParser(EditForm target)
        {
            this.target = target;
        }

        public string Parse(object sender, ParseCommandEventArgs e)
        {
            string result;
            result = e.Original.Replace("%f", target.filepath);
            result = result.Replace("%p", e.PageNumber.ToString());
            return result;
        }
    }
}
