[{"id":"3d06deaa-2e4d-479c-b95a-2dcb8abfc887","tags":[{"product":null,"links":null,"id":"92283933-94f9-4e9a-8d93-15ba4ec8b3ec","name":"upd","color":"#7e678a","productId":"77f3d9a0-2c87-4130-b77a-b94ccf13e3cb"}]},{"id":"e822faa9-5b39-474c-8f04-d95dcd787a4e","tags":[{"product":null,"links":null,"id":"92283933-94f9-4e9a-8d93-15ba4ec8b3ec","name":"upd","color":"#7e678a","productId":"77f3d9a0-2c87-4130-b77a-b94ccf13e3cb"}]},{"id":"091ec731-67fd-4a2a-a703-3728fe885481","tags":[{"product":null,"links":null,"id":"92283933-94f9-4e9a-8d93-15ba4ec8b3ec","name":"upd","color":"#7e678a","productId":"77f3d9a0-2c87-4130-b77a-b94ccf13e3cb"}]},{"id":"c4d1bedb-691f-49bb-96ed-65f91b580b0c","tags":[{"product":null,"links":null,"id":"92283933-94f9-4e9a-8d93-15ba4ec8b3ec","name":"upd","color":"#7e678a","productId":"77f3d9a0-2c87-4130-b77a-b94ccf13e3cb"}]},{"id":"83de1fff-256a-4bcf-9d47-c12ac032a9e4","tags":[{"product":null,"links":null,"id":"92283933-94f9-4e9a-8d93-15ba4ec8b3ec","name":"upd","color":"#7e678a","productId":"77f3d9a0-2c87-4130-b77a-b94ccf13e3cb"}]},{"id":"844918ae-7b53-4e16-8a83-4d9203303aa2","tags":[{"product":null,"links":null,"id":"92283933-94f9-4e9a-8d93-15ba4ec8b3ec","name":"upd","color":"#7e678a","productId":"77f3d9a0-2c87-4130-b77a-b94ccf13e3cb"}]},{"id":"eaf39ba6-65df-466b-bc99-d40907e64e8e","tags":[{"product":null,"links":null,"id":"92283933-94f9-4e9a-8d93-15ba4ec8b3ec","name":"upd","color":"#7e678a","productId":"77f3d9a0-2c87-4130-b77a-b94ccf13e3cb"}]},{"id":"65c6fd4f-dc15-4112-b00a-45207cea85fc","tags":[{"product":null,"links":null,"id":"e1d31134-0bda-4c05-bee0-b1f21f82940b","name":"new","color":"#00A273","productId":"77f3d9a0-2c87-4130-b77a-b94ccf13e3cb"}]},{"id":"460f9118-8a3c-40da-8eba-63a1ba9df454","tags":[{"product":null,"links":null,"id":"e1d31134-0bda-4c05-bee0-b1f21f82940b","name":"new","color":"#00A273","productId":"77f3d9a0-2c87-4130-b77a-b94ccf13e3cb"}]},{"id":"d2fc8bc1-89bf-4483-a3c2-be4be40fff31","tags":[{"product":null,"links":null,"id":"92283933-94f9-4e9a-8d93-15ba4ec8b3ec","name":"upd","color":"#7e678a","productId":"77f3d9a0-2c87-4130-b77a-b94ccf13e3cb"}]},{"id":"b63907ef-97db-412d-b9e9-61e1cb319d27","tags":[{"product":null,"links":null,"id":"92283933-94f9-4e9a-8d93-15ba4ec8b3ec","name":"upd","color":"#7e678a","productId":"77f3d9a0-2c87-4130-b77a-b94ccf13e3cb"}]},{"id":"d7124176-a563-4cf4-8f9a-f8ae3af669ac","tags":[{"product":null,"links":null,"id":"92283933-94f9-4e9a-8d93-15ba4ec8b3ec","name":"upd","color":"#7e678a","productId":"77f3d9a0-2c87-4130-b77a-b94ccf13e3cb"}]},{"id":"f1ef6a79-1200-4477-bf3b-d1f4b52bf586","tags":[{"product":null,"links":null,"id":"92283933-94f9-4e9a-8d93-15ba4ec8b3ec","name":"upd","color":"#7e678a","productId":"77f3d9a0-2c87-4130-b77a-b94ccf13e3cb"}]},{"id":"4b1a964f-7b24-4943-a2e2-77ff450e1f1d","tags":[{"product":null,"links":null,"id":"92283933-94f9-4e9a-8d93-15ba4ec8b3ec","name":"upd","color":"#7e678a","productId":"77f3d9a0-2c87-4130-b77a-b94ccf13e3cb"}]},{"id":"ab703b5b-c2f4-48dc-925d-878261bce75f","tags":[{"product":null,"links":null,"id":"e1d31134-0bda-4c05-bee0-b1f21f82940b","name":"new","color":"#00A273","productId":"77f3d9a0-2c87-4130-b77a-b94ccf13e3cb"}]},{"id":"a4de2920-3951-4baf-a478-888961b5e3c4","tags":[{"product":null,"links":null,"id":"e1d31134-0bda-4c05-bee0-b1f21f82940b","name":"new","color":"#00A273","productId":"77f3d9a0-2c87-4130-b77a-b94ccf13e3cb"}]}]
Webデザイナコンポーネントは、デフォルトでTextBoxなどのレポートコントロールに使用できる事前定義されたフォントのリストを使用します。また、ActiveReportsJSのAPIを使用すると、Google Fontsのようなカスタムフォントを登録して、レポートで使用できます。
フォントを登録するための基本的な方法はFontDescriptorです。以下は、Robotoフォントを定義するFontDescriptorインスタンスのサンプルです。
const robotoFont = {
name: "Roboto",
source:
"https://fonts.gstatic.com/s/roboto/v20/KFOkCnqEu92Fr1MmgVxIIzI.woff2",
};
FontStore
オブジェクトのregisterFont
メソッドは、次のようにフォント記述子オブジェクトを受け取り、指定されたフォントを登録します。
import { Core } from "@grapecity/activereports";
await Core.FontStore.registerFonts(robotoFont);
アプリケーションは、Webデザイナコンポーネントを初期化する前に上記のコードを呼び出す必要があります。
また、同じAPIを使用して、ActiveReportJSビューワのインスタンスのカスタムフォントを登録します。詳細については、フォントの登録を参照してください。
WebデザイナコンポーネントのfontSetプロパティを使用して、レポートを設計する時に使用できるフォントのリストを操作できます。このプロパティで設定可能な値は以下のとおりです。