概要
Query に適合する Text Color プロパティを持つ、すべてのハーネスエントリ、注記、ポート、シートエントリ、およびテキストフレームオブジェクトを返します。
構文
TextColor : Numeric_String
TextColor : Number
TextColor キーワードは、常に Numeric_String と組み合わせて使用できます。代わりに Number と組み合わせて使用することもできますが、その場合は only 他のすべてのオブジェクト(Text Color プロパティを持たないもの)が、Query 式内の 1 つ以上の先行エントリによって完全に除外されているときに限ります。式内では、TextColor <> '' や TextColor > '' のようなエントリを使用してください。あるいは、IsPort、IsTextFrame のように、ポートおよびテキストフレームオブジェクトを明示的に対象とするエントリを使用してください。
特定の数値に対応する色は、次の関係から導き出せます:
65536 * Blue + 256 * Green + Red
ここで、Blue、Green、および Red の各成分は、それぞれ 0 から 255 まで(両端を含む)の値を取ります。
TextColor キーワードを Number と組み合わせて使用できる場合、次の構文を使用して、Text Color プロパティの Blue、Green、Red の各成分の値を個別に評価できます:
-
Blue = Text Color Div 65536
-
Green = Text Color Div 256 Mod 256
-
Red = Text Color Mod 256
使用例
TextColor = '0'
TextColor <> '' && TextColor = 0
Blue = 0、Green = 0、Red = 0 に対応する 0 である Text Color プロパティを持つ、すべてのハーネスエントリ、注記、ポート、シートエントリ、およびテキストフレームオブジェクトを返します。
TextColor = '32896'
TextColor > '' && TextColor = 32896
harness entry、note、port、sheet entry、および text frame オブジェクトのうち、Text Color プロパティが 32896 であるものをすべて返します(これは Blue = 0、Green = 128、Red = 128 の値に対応します)。
TextColor <> '16777215'
harness entry、note、port、sheet entry、および text frame オブジェクトを除くすべてのオブジェクトのうち、Text Color プロパティが 16777215 であるものをすべて返します(これは Blue = 255、Green = 255、Red = 255 の値に対応します)。
IsPort Or IsTextFrame && TextColor <> 16777215
port または text frame オブジェクトのうち、Text Color プロパティが 16777215 ではないものをすべて返します。
TextColor > '' && TextColor Div 65536 >= 96 && TextColor Div 256 Mod 256 Between 64 And 192 && TextColor Mod 256 <= 128
harness entry、note、port、sheet entry、および text frame オブジェクトのうち、Text Color プロパティについて、Blue コンポーネントの値が 96 以上、Green コンポーネントの値が 64 以上かつ 192 以下、Red コンポーネントの値が 128 以下であるものをすべて返します。
IsTextFrame && TextColor Div 65536 <= 192
text frame オブジェクトのうち、Text Color プロパティの Blue コンポーネントの値が 192 以下であるものをすべて返します。
IsPort && TextColor Mod 256 Between 64 And 192
port オブジェクトのうち、Text Color プロパティの Red コンポーネントの値が 64 以上かつ 192 以下であるものをすべて返します。
注記
Text Color プロパティは、harness entry、note、port、sheet entry、および text frame オブジェクトに対してのみ定義されています。