57 references to Constants
PresentationCore (57)
Core\CSharp\MS\Internal\FontFace\CompositeFontParser.cs (8)
42
else if (value >
Constants
.GreatestMutiplierOfEm)
44
value =
Constants
.GreatestMutiplierOfEm;
46
else if (value < -
Constants
.GreatestMutiplierOfEm)
48
value = -
Constants
.GreatestMutiplierOfEm;
58
else if (value >
Constants
.GreatestMutiplierOfEm)
60
value =
Constants
.GreatestMutiplierOfEm;
74
else if (value >
Constants
.GreatestMutiplierOfEm)
76
value =
Constants
.GreatestMutiplierOfEm;
Core\CSharp\MS\Internal\TextFormatting\FormatSettings.cs (4)
64
_maxLineWidth =
Constants
.IdealInfiniteWidth;
165
return _pap.Wrap ? finiteFormatWidth :
Constants
.IdealInfiniteWidth;
176
int formatWidth = (paragraphWidth <= 0 ?
Constants
.IdealInfiniteWidth : paragraphWidth);
181
formatWidth = Math.Min(formatWidth,
Constants
.IdealInfiniteWidth);
Core\CSharp\MS\Internal\TextFormatting\FullTextState.cs (1)
117
Constants
.IdealInfiniteWidth // formatWidth
Core\CSharp\MS\Internal\TextFormatting\LineServicesCallbacks.cs (8)
492
lstTextMetrics.dvAscent = (int)Math.Round(typeface.Baseline(store.Pap.EmSize,
Constants
.DefaultIdealToReal, store.Settings.TextSource.PixelsPerDip, fullText.TextFormattingMode));
493
lstTextMetrics.dvMultiLineHeight = (int)Math.Round(typeface.LineSpacing(store.Pap.EmSize,
Constants
.DefaultIdealToReal, store.Settings.TextSource.PixelsPerDip, fullText.TextFormattingMode));
2035
(int)(lsrun.EmSize *
Constants
.MinInterWordCompressionPerEm),
2090
(int)(lsrun.EmSize *
Constants
.MaxInterWordExpansionPerEm),
2149
pplsAdjustRight[1][i] = expandedBy *
Constants
.AcceptableLineStretchability;
2203
(int)(em *
Constants
.MinInterWordCompressionPerEm),
2339
(int)(em *
Constants
.MaxInterWordExpansionPerEm),
2433
pplsExpansionRight[1][igi + i] = expandedBy *
Constants
.AcceptableLineStretchability;
Core\CSharp\MS\Internal\TextFormatting\SimpleTextLine.cs (2)
339
_height = formatter.IdealToReal((int)Math.Round(pap.DefaultTypeface.LineSpacing(pap.EmSize,
Constants
.DefaultIdealToReal, PixelsPerDip, _settings.TextFormattingMode)), PixelsPerDip);
340
_baselineOffset = formatter.IdealToReal((int)Math.Round(pap.DefaultTypeface.Baseline(pap.EmSize,
Constants
.DefaultIdealToReal, PixelsPerDip, _settings.TextFormattingMode)), PixelsPerDip);
Core\CSharp\MS\Internal\TextFormatting\TextFormatterImp.cs (13)
492
|| paragraphWidth >
Constants
.RealInfiniteWidth)
494
throw new ArgumentOutOfRangeException("paragraphWidth", SR.Get(SRID.ParameterMustBeBetween, 0,
Constants
.RealInfiniteWidth));
497
double realMaxFontRenderingEmSize =
Constants
.RealInfiniteWidth /
Constants
.GreatestMutiplierOfEm;
505
if (paragraphProperties.Indent >
Constants
.RealInfiniteWidth)
506
throw new ArgumentOutOfRangeException("paragraphProperties.Indent", SR.Get(SRID.ParameterCannotBeGreaterThan,
Constants
.RealInfiniteWidth));
508
if (paragraphProperties.LineHeight >
Constants
.RealInfiniteWidth)
509
throw new ArgumentOutOfRangeException("paragraphProperties.LineHeight", SR.Get(SRID.ParameterCannotBeGreaterThan,
Constants
.RealInfiniteWidth));
512
|| paragraphProperties.DefaultIncrementalTab >
Constants
.RealInfiniteWidth)
514
throw new ArgumentOutOfRangeException("paragraphProperties.DefaultIncrementalTab", SR.Get(SRID.ParameterMustBeBetween, 0,
Constants
.RealInfiniteWidth));
728
return i *
Constants
.DefaultIdealToReal;
745
value = Math.Max(value,
Constants
.DefaultIdealToReal);
791
get { return
Constants
.DefaultRealToIdeal; }
Core\CSharp\MS\Internal\TextFormatting\TextMetrics.cs (4)
213
* pap.DefaultTypeface.Baseline(pap.EmSize,
Constants
.DefaultIdealToReal, _pixelsPerDip, fullText.TextFormattingMode)
214
/ pap.DefaultTypeface.LineSpacing(pap.EmSize,
Constants
.DefaultIdealToReal, _pixelsPerDip, fullText.TextFormattingMode)
222
_textAscent = (int)Math.Round(pap.DefaultTypeface.Baseline(pap.EmSize,
Constants
.DefaultIdealToReal, _pixelsPerDip, fullText.TextFormattingMode));
223
_textHeight = (int)Math.Round(pap.DefaultTypeface.LineSpacing(pap.EmSize,
Constants
.DefaultIdealToReal, _pixelsPerDip, fullText.TextFormattingMode));
Core\CSharp\MS\Internal\TextFormatting\TextRunCacheImp.cs (2)
141
double realMaxFontRenderingEmSize =
Constants
.RealInfiniteWidth /
Constants
.GreatestMutiplierOfEm;
Core\CSharp\MS\Internal\TextFormatting\TextStore.cs (2)
2380
_settings.Formatter.IdealToReal((
Constants
.IdealInfiniteWidth - currentPosition), _settings.TextSource.PixelsPerDip),
2385
else if (metrics.Width > _settings.Formatter.IdealToReal((
Constants
.IdealInfiniteWidth - currentPosition), _settings.TextSource.PixelsPerDip))
Core\CSharp\System\Windows\Media\CharacterMetrics.cs (8)
18
using Constants = MS.Internal.TextFormatting.
Constants
;
309
int hash = (int)(_blackBoxWidth *
Constants
.DefaultRealToIdeal);
310
hash = (hash * HashMultiplier) + (int)(_blackBoxHeight *
Constants
.DefaultRealToIdeal);
311
hash = (hash * HashMultiplier) + (int)(_baseline *
Constants
.DefaultRealToIdeal);
312
hash = (hash * HashMultiplier) + (int)(_leftSideBearing *
Constants
.DefaultRealToIdeal);
313
hash = (hash * HashMultiplier) + (int)(_rightSideBearing *
Constants
.DefaultRealToIdeal);
314
hash = (hash * HashMultiplier) + (int)(_topSideBearing *
Constants
.DefaultRealToIdeal);
315
hash = (hash * HashMultiplier) + (int)(_bottomSideBearing *
Constants
.DefaultRealToIdeal);
Core\CSharp\System\Windows\Media\FormattedText.cs (2)
2058
const double MaxFontEmSize =
Constants
.RealInfiniteWidth /
Constants
.GreatestMutiplierOfEm;
Core\CSharp\System\Windows\Media\TextFormatting\TextParagraphCache.cs (3)
200
return
Constants
.IdealInfiniteWidth;
204
|| maxLineWidth >
Constants
.RealInfiniteWidth)
206
throw new ArgumentOutOfRangeException("maxLineWidth", SR.Get(SRID.ParameterMustBeBetween, 0,
Constants
.RealInfiniteWidth));