Skip to content

get_fontGetFontGetFontget_fontT_get_font🔗

説明🔗

get_fontGetFontGetFontget_fontT_get_font — 現在設定されているフォントを得る。

書式🔗

get_font( window WindowHandle, out string Font )void GetFont( const HTuple& WindowHandle, HTuple* Font )static void HOperatorSet.GetFont( HTuple windowHandle, out HTuple font )def get_font( window_handle: HHandle ) -> str

Herror T_get_font( const Htuple WindowHandle, Htuple* Font )

HString HWindow::GetFont( ) const

string HWindow.GetFont( )

説明🔗

get_fontGetFont は、出力ウインドウ WindowHandlewindowHandlewindow_handle内で使用されているフォント名を 取得します。フォントは、オペレーター write_stringWriteString、 read_stringReadString などによって使用されます。フォントは、 オペレーター set_fontSetFont によって設定されます。画像表示に対する ウインドウと同様にテキストウインドウもこの設定のフォントを使用します。両方の タイプのウインドウは、デフォルトフォントを持ち、 ウインドウを開く前に set_system('default_font',Font) を 用いて変更可能です。すべての利用可能なフォントのリストは、 query_fontQueryFont を使用して得ることができます。

実行情報🔗

実行情報
  • マルチスレッドタイプ: リエントラント(非排他なオペレーターと並列に動作)

  • マルチスレッドスコープ: グローバル(他のスレッドから呼び出される可能性あり)

  • 並列演算処理には未対応

パラメーター🔗

WindowHandlewindowHandlewindow_handle (input_control) window → (handle)HTuple (HHandle)HWindow, HTuple (IntPtr)HHandleHtuple (handle)

ウインドウハンドル

Fontfontfont (output_control) string → (string)HTuple (HString)HTuple (string)strHtuple (char*)

現在のフォントの名前

例🔗

(HDevelop)


get_font(WindowHandle,CurrentFont)
set_font(WindowHandle,MyFont)
write_string(WindowHandle,['The name of my Font is:',Myfont])
new_line(WindowHandle)
set_font(WindowHandle,CurrentFont)
(C)
T_get_font(WindowHandle,&CurrentFont)\;
T_set_font(WindowHandle,MyFont)\;
sprintf(buf,"The name of my Font is: %s ",get_s(Myfont,0)\;
create_tuple_s(&String,buf)\;
T_write_string(WindowHandle,String)\;
T_new_line(WindowHandle)\;
T_set_font(WindowHandle,CurrentFont)\;

結果🔗

get_fontGetFont は、値 2 (H_MSG_TRUE) を返します。

他のオペレーターとの組み合わせ🔗

組み合わせ

前処理の候補

open_windowOpenWindow, query_fontQueryFont

後処理の候補

set_fontSetFont

関連項目

set_fontSetFont, query_fontQueryFont, open_windowOpenWindow, set_systemSetSystem

モジュール🔗

Foundation