Bug 1457373 - Remove text-combine-upright digits option - r?
MozReview-Commit-ID: Ehzsd2rmBER
--- a/layout/base/nsLayoutUtils.cpp
+++ b/layout/base/nsLayoutUtils.cpp
@@ -184,17 +184,16 @@ typedef nsStyleTransformMatrix::Transfor
/* static */ bool nsLayoutUtils::sFontSizeInflationForceEnabled;
/* static */ bool nsLayoutUtils::sFontSizeInflationDisabledInMasterProcess;
/* static */ uint32_t nsLayoutUtils::sSystemFontScale;
/* static */ uint32_t nsLayoutUtils::sZoomMaxPercent;
/* static */ uint32_t nsLayoutUtils::sZoomMinPercent;
/* static */ bool nsLayoutUtils::sInvalidationDebuggingIsEnabled;
/* static */ bool nsLayoutUtils::sInterruptibleReflowEnabled;
/* static */ bool nsLayoutUtils::sSVGTransformBoxEnabled;
-/* static */ bool nsLayoutUtils::sTextCombineUprightDigitsEnabled;
/* static */ uint32_t nsLayoutUtils::sIdlePeriodDeadlineLimit;
/* static */ uint32_t nsLayoutUtils::sQuiescentFramesBeforeIdlePeriod;
static ViewID sScrollIdCounter = FrameMetrics::START_SCROLL_ID;
typedef nsDataHashtable<nsUint64HashKey, nsIContent*> ContentMap;
static ContentMap* sContentMap = nullptr;
static ContentMap& GetContentMap() {
@@ -8067,18 +8066,16 @@ nsLayoutUtils::Initialize()
Preferences::AddUintVarCache(&sZoomMinPercent,
"zoom.minPercent", 30);
Preferences::AddBoolVarCache(&sInvalidationDebuggingIsEnabled,
"nglayout.debug.invalidation");
Preferences::AddBoolVarCache(&sInterruptibleReflowEnabled,
"layout.interruptible-reflow.enabled");
Preferences::AddBoolVarCache(&sSVGTransformBoxEnabled,
"svg.transform-box.enabled");
- Preferences::AddBoolVarCache(&sTextCombineUprightDigitsEnabled,
- "layout.css.text-combine-upright-digits.enabled");
Preferences::AddUintVarCache(&sIdlePeriodDeadlineLimit,
"layout.idle_period.time_limit",
DEFAULT_IDLE_PERIOD_TIME_LIMIT);
Preferences::AddUintVarCache(&sQuiescentFramesBeforeIdlePeriod,
"layout.idle_period.required_quiescent_frames",
DEFAULT_QUIESCENT_FRAMES);
nsComputedDOMStyle::RegisterPrefChangeCallbacks();
--- a/layout/base/nsLayoutUtils.h
+++ b/layout/base/nsLayoutUtils.h
@@ -2516,20 +2516,16 @@ public:
static float MinZoom() {
return sZoomMinPercent / 100.0f;
}
static bool SVGTransformBoxEnabled() {
return sSVGTransformBoxEnabled;
}
- static bool TextCombineUprightDigitsEnabled() {
- return sTextCombineUprightDigitsEnabled;
- }
-
static uint32_t IdlePeriodDeadlineLimit() {
return sIdlePeriodDeadlineLimit;
}
static uint32_t QuiescentFramesBeforeIdlePeriod() {
return sQuiescentFramesBeforeIdlePeriod;
}
@@ -3126,17 +3122,16 @@ private:
static bool sFontSizeInflationForceEnabled;
static bool sFontSizeInflationDisabledInMasterProcess;
static uint32_t sSystemFontScale;
static uint32_t sZoomMaxPercent;
static uint32_t sZoomMinPercent;
static bool sInvalidationDebuggingIsEnabled;
static bool sInterruptibleReflowEnabled;
static bool sSVGTransformBoxEnabled;
- static bool sTextCombineUprightDigitsEnabled;
static uint32_t sIdlePeriodDeadlineLimit;
static uint32_t sQuiescentFramesBeforeIdlePeriod;
/**
* Helper function for LogTestDataForPaint().
*/
static void DoLogTestDataForPaint(mozilla::layers::LayerManager* aManager,
ViewID aScrollId,
--- a/layout/style/nsCSSKeywordList.h
+++ b/layout/style/nsCSSKeywordList.h
@@ -230,17 +230,16 @@ CSS_KEY(darken, darken)
CSS_KEY(dashed, dashed)
CSS_KEY(dense, dense)
CSS_KEY(decimal, decimal)
CSS_KEY(default, default)
CSS_KEY(deg, deg)
CSS_KEY(diagonal-fractions, diagonal_fractions)
CSS_KEY(dialog, dialog)
CSS_KEY(difference, difference)
-CSS_KEY(digits, digits)
CSS_KEY(disabled, disabled)
CSS_KEY(disc, disc)
CSS_KEY(discretionary-ligatures, discretionary_ligatures)
CSS_KEY(distribute, distribute)
CSS_KEY(dot, dot)
CSS_KEY(dotted, dotted)
CSS_KEY(double, double)
CSS_KEY(double-circle, double_circle)
--- a/layout/style/nsCSSProps.cpp
+++ b/layout/style/nsCSSProps.cpp
@@ -1246,17 +1246,16 @@ const KTableEntry nsCSSProps::kTextJusti
// the exact same meaning and behavior as "inter-character".
{ eCSSKeyword_distribute, StyleTextJustify::InterCharacter },
{ eCSSKeyword_UNKNOWN, -1 }
};
const KTableEntry nsCSSProps::kTextCombineUprightKTable[] = {
{ eCSSKeyword_none, NS_STYLE_TEXT_COMBINE_UPRIGHT_NONE },
{ eCSSKeyword_all, NS_STYLE_TEXT_COMBINE_UPRIGHT_ALL },
- { eCSSKeyword_digits, NS_STYLE_TEXT_COMBINE_UPRIGHT_DIGITS_2 }, // w/o number ==> 2
{ eCSSKeyword_UNKNOWN, -1 }
};
const KTableEntry nsCSSProps::kTextDecorationLineKTable[] = {
{ eCSSKeyword_none, NS_STYLE_TEXT_DECORATION_LINE_NONE },
{ eCSSKeyword_underline, NS_STYLE_TEXT_DECORATION_LINE_UNDERLINE },
{ eCSSKeyword_overline, NS_STYLE_TEXT_DECORATION_LINE_OVERLINE },
{ eCSSKeyword_line_through, NS_STYLE_TEXT_DECORATION_LINE_LINE_THROUGH },
--- a/layout/style/nsComputedDOMStyle.cpp
+++ b/layout/style/nsComputedDOMStyle.cpp
@@ -4175,27 +4175,19 @@ nsComputedDOMStyle::DoGetTextAlignLast()
}
already_AddRefed<CSSValue>
nsComputedDOMStyle::DoGetTextCombineUpright()
{
RefPtr<nsROCSSPrimitiveValue> val = new nsROCSSPrimitiveValue;
uint8_t tch = StyleText()->mTextCombineUpright;
- if (tch <= NS_STYLE_TEXT_COMBINE_UPRIGHT_ALL) {
- val->SetIdent(
- nsCSSProps::ValueToKeywordEnum(tch,
- nsCSSProps::kTextCombineUprightKTable));
- } else if (tch <= NS_STYLE_TEXT_COMBINE_UPRIGHT_DIGITS_2) {
- val->SetString(NS_LITERAL_STRING("digits 2"));
- } else if (tch <= NS_STYLE_TEXT_COMBINE_UPRIGHT_DIGITS_3) {
- val->SetString(NS_LITERAL_STRING("digits 3"));
- } else {
- val->SetString(NS_LITERAL_STRING("digits 4"));
- }
+ val->SetIdent(
+ nsCSSProps::ValueToKeywordEnum(tch,
+ nsCSSProps::kTextCombineUprightKTable));
return val.forget();
}
already_AddRefed<CSSValue>
nsComputedDOMStyle::DoGetTextDecoration()
{
const nsStyleTextReset* textReset = StyleTextReset();
--- a/layout/style/nsStyleConsts.h
+++ b/layout/style/nsStyleConsts.h
@@ -894,19 +894,16 @@ enum class StyleWhiteSpace : uint8_t {
// See nsStyleText
#define NS_STYLE_TEXT_ORIENTATION_MIXED 0
#define NS_STYLE_TEXT_ORIENTATION_UPRIGHT 1
#define NS_STYLE_TEXT_ORIENTATION_SIDEWAYS 2
// See nsStyleText
#define NS_STYLE_TEXT_COMBINE_UPRIGHT_NONE 0
#define NS_STYLE_TEXT_COMBINE_UPRIGHT_ALL 1
-#define NS_STYLE_TEXT_COMBINE_UPRIGHT_DIGITS_2 2
-#define NS_STYLE_TEXT_COMBINE_UPRIGHT_DIGITS_3 3
-#define NS_STYLE_TEXT_COMBINE_UPRIGHT_DIGITS_4 4
// See nsStyleText
#define NS_STYLE_LINE_HEIGHT_BLOCK_HEIGHT 0
// See nsStyleText
#define NS_STYLE_UNICODE_BIDI_NORMAL 0x0
#define NS_STYLE_UNICODE_BIDI_EMBED 0x1
#define NS_STYLE_UNICODE_BIDI_ISOLATE 0x2
--- a/layout/style/test/property_database.js
+++ b/layout/style/test/property_database.js
@@ -6315,21 +6315,16 @@ if (IsCSSPropertyPrefEnabled("layout.css
"pan-x pan-y pan-x", "pan-x pan-x pan-y", "pan-y pan-x pan-x", "pan-y pan-x pan-y", "pan-y pan-y pan-x", "pan-x pan-y pan-y",
"manipulation none", "none manipulation", "manipulation auto", "auto manipulation", "manipulation zoom", "zoom manipulation",
"manipulation manipulation", "manipulation pan-x", "pan-x manipulation", "manipulation pan-y", "pan-y manipulation",
"manipulation pan-x pan-y", "pan-x manipulation pan-y", "pan-x pan-y manipulation",
"manipulation pan-y pan-x", "pan-y manipulation pan-x", "pan-y pan-x manipulation"]
};
}
-if (IsCSSPropertyPrefEnabled("layout.css.text-combine-upright-digits.enabled")) {
- gCSSProperties["text-combine-upright"].other_values.push(
- "digits", "digits 2", "digits 3", "digits 4", "digits 3");
-}
-
if (IsCSSPropertyPrefEnabled("layout.css.text-justify.enabled")) {
gCSSProperties["text-justify"] = {
domProp: "textJustify",
inherited: true,
type: CSS_TYPE_LONGHAND,
applies_to_placeholder: true,
initial_values: [ "auto" ],
other_values: [ "none", "inter-word", "inter-character", "distribute" ],
--- a/modules/libpref/init/all.js
+++ b/modules/libpref/init/all.js
@@ -2905,19 +2905,16 @@ pref("layout.css.prefixes.transforms", t
pref("layout.css.prefixes.transitions", true);
pref("layout.css.prefixes.animations", true);
pref("layout.css.prefixes.box-sizing", true);
pref("layout.css.prefixes.font-features", true);
// Is support for background-blend-mode enabled?
pref("layout.css.background-blend-mode.enabled", true);
-// Is support for CSS text-combine-upright: digits 2-4 enabled?
-pref("layout.css.text-combine-upright-digits.enabled", false);
-
// Is -moz-osx-font-smoothing enabled?
// Only supported in OSX builds
#ifdef XP_MACOSX
pref("layout.css.osx-font-smoothing.enabled", true);
#else
pref("layout.css.osx-font-smoothing.enabled", false);
#endif