laptop and a wrench

不具合

The method ESRI.ArcGIS.ADF.Web.Display.Symbol.TextMarkerSymbol::GetDimensions returns wrong values of width and height.

最後に公開された状態: August 25, 2014 No Product Found
不具合 ID 番号 NIM012109
送信されましたOctober 3, 2007
最終更新日June 5, 2024
適用対象No Product Found
見つかったバージョン9.2
ステータスWill Not Be Addressed

参考情報

No Public Explanation

対処法

The font size is in point unit, which varies according to different font. For example, for font "Arial", the size 20 means 31 pt height; and for the font "Snap ITC", the same size means 35 pt height.Another thing needs to notice is that the formula to convert point unit into pixel unit, 1 pt = 1 px * 1.333.We could get the text string width and height in a specific font through GDI+ directly. Please see code below: //get the text string width and height through GDI+ directly without touching ESRI class System.Drawing.Font font = new System.Drawing.Font("Snap ITC", 20); Bitmap image = new Bitmap(1, 1); Graphics g = Graphics.FromImage(image); double width = g.MeasureString("Hello World!", font).Width; double height = g.MeasureString("Hello World!", font).Height; int widthInt = Convert.ToInt16(width/1.333); int heightInt = Convert.ToInt16(height/1.333);

再現の手順

不具合 ID: NIM012109

ソフトウェア:

  • No Product Found

バグのステータスが変更されたときに通知を受け取る

Esri Support アプリのダウンロード

このトピックについてさらに調べる

ArcGIS エキスパートのサポートを受ける

テクニカル サポートへのお問い合わせ

Esri Support アプリのダウンロード

ダウンロード オプションに移動