ここでは、Poderosa V3.0系 に対して私が行った、改造等を紹介します。基本的には、マクロ作成時に必要となった機能ばかりなのですが、これらの機能は、他の用途としても有効だと考えています。
- Caption(get/set)
- 接続中のウィンドウのタブタイトルを変更できます。
- LogAppend(get), LogType(get), LogPath(get)
- ログ出力の設定情報を取得できます。
- RenderProfile(get)
- 接続中のウィンドウに対して、RenderProfile に関する属性などを変更できます。
- ApplyRenderProfile(RenderProfile prop)
- 接続中のウィンドウの RenderProfile 情報を変更します。 フォント、フォントサイズ、文字色、背景色などを変更することができるようになります。
- ResetLog(LogType type, string path, bool append)
- ログ出力制御情報を変更できます。 これにより、ログ出力の開始/停止、ログファイル名の変更等が行えるようになります。
- 差分:poderosa/Container/MacroEnv.cs(390)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50
|
--- cvs\Poderosa\src\Container\MacroEnv.cs Wed Apr 20 17:45:45 2005
+++ dev\Poderosa\src\Container\MacroEnv.cs Wed Sep 07 19:32:14 2005
@@ -80,6 +80,34 @@
return _tag.Connection.TerminalHeight;
}
}
+ public override string Caption {
+ get {
+ return _tag.Connection.Param.Caption;
+ }
+ set {
+ _tag.Connection.Param.Caption = value;
+ }
+ }
+ public override bool LogAppend {
+ get {
+ return _tag.Connection.Param.LogAppend;
+ }
+ }
+ public override string LogPath {
+ get {
+ return _tag.Connection.Param.LogPath;
+ }
+ }
+ public override LogType LogType {
+ get {
+ return _tag.Connection.Param.LogType;
+ }
+ }
+ public override RenderProfile RenderProfile {
+ get {
+ return _tag.RenderProfile;
+ }
+ }
public override void Activate() {
GApp.InterThreadUIService.ActivateConnection(_tag);
@@ -112,6 +140,12 @@
public override void WriteComment(string comment) {
_tag.Terminal.Logger.Comment(comment);
}
+ public override void ApplyRenderProfile(RenderProfile prop) {
+ if (_tag.AttachedPane!=null) _tag.AttachedPane.ApplyRenderProfile(prop);
+ }
+ public override void ResetLog(LogType type, string path, bool append) {
+ _tag.Connection.ResetLog(type, path, append);
+ }
}
internal class FrameImpl : Frame {
|
- 差分:poderosa/Container/MacroInterface.cs(390)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68
|
--- cvs\Poderosa\src\Container\MacroInterface.cs Wed Apr 20 17:45:45 2005
+++ dev\Poderosa\src\Container\MacroInterface.cs Wed Sep 07 19:27:06 2005
@@ -10,6 +10,7 @@
using Poderosa.Config;
#endif
+using Poderosa.Terminal;
using Poderosa.Toolkit;
namespace Poderosa.Macro {
@@ -213,6 +214,31 @@
/// <en>Gets the height of the console in characters.</en>
/// </summary>
public abstract int TerminalHeight { get; }
+ /// <summary>
+ /// <ja>この接続のタブなどに表示する為の見出しです。</ja>
+ /// <en>Gets or sets the caption of the tab.</en>
+ /// </summary>
+ public abstract string Caption{ get; set; }
+ /// <summary>
+ /// <ja>ログファイルに追記するか上書きするかの設定を取得します。</ja>
+ /// <en>Gets the Specifies whether the connection appends or overwrites the log file.</en>
+ /// </summary>
+ public abstract bool LogAppend { get; }
+ /// <summary>
+ /// <ja>ログファイルのフルパスを取得します。</ja>
+ /// <en>Gets the full path of the log file.</en>
+ /// </summary>
+ public abstract string LogPath { get; }
+ /// <summary>
+ /// <ja>ログの種別を取得します。</ja>
+ /// <en>Gets the type of the log.</en>
+ /// </summary>
+ public abstract LogType LogType { get; }
+ /// <summary>
+ /// <ja>このTerminalParamで接続を開いたときの色・フォントなどの設定を収録したオブジェクトです。</ja>
+ /// <en>Gets or sets the appearances of the console such as colors or fonts.</en>
+ /// </summary>
+ public abstract RenderProfile RenderProfile{ get; }
/// <summary>
/// <ja>この接続をアクティブにし、最前面に持っていきます。</ja>
@@ -363,6 +389,25 @@
/// </example>
/// <param name="comment"><ja>コメント文字列</ja><en>The comment string</en></param>
public abstract void WriteComment(string comment);
+
+ /// <summary>
+ /// <ja>この接続の、色・フォントなどの設定を更新します。</ja>
+ /// <en>The appearances of apply this connection such as colors or fonts. </en>
+ /// </summary>
+ /// <param name="prof">
+ /// <ja>色・フォントなどの設定を収録したオブジェクト</ja>
+ /// <en>The appearances of the console such as colors or fonts.</en>
+ /// </param>
+ public abstract void ApplyRenderProfile(RenderProfile prof);
+
+ /// <summary>
+ /// <ja>ログ設定をリセットします。</ja>
+ /// <en>A log setup of this connection is reset.</en>
+ /// </summary>
+ /// <param name="type"><ja>ログの種別</ja><en>The type of the log</en></param>
+ /// <param name="path"><ja>ログファイルのフルパス</ja><en>The full path of the log file</en></param>
+ /// <param name="append"><ja>追記するか上書きするかを指定</ja><en>Appends or overwrites the log file</en></param>
+ public abstract void ResetLog(LogType type, string path, bool append);
}
/// <summary>
|
最終更新時間:2005/11/14-09:42:19