diff options
author | tfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-11-14 04:14:48 +0000 |
---|---|---|
committer | tfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-11-14 04:14:48 +0000 |
commit | 0d3b9dda19ce9f3fb74e601146ac9f1f1d68dfbe (patch) | |
tree | 39b348736b26c4e45d8fe6fc4ca2054d89b48320 /ui/gfx | |
parent | 16dbfb0e842b3ebb5dc156dc4b0990dc7dfa04db (diff) | |
download | chromium_src-0d3b9dda19ce9f3fb74e601146ac9f1f1d68dfbe.zip chromium_src-0d3b9dda19ce9f3fb74e601146ac9f1f1d68dfbe.tar.gz chromium_src-0d3b9dda19ce9f3fb74e601146ac9f1f1d68dfbe.tar.bz2 |
ui/gfx: Create a new gfx switches file to put gfx specific switches there.
BUG=103304
TEST=ui_unittests
R=sky@chromium.org
Review URL: https://chromiumcodereview.appspot.com/11359184
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@167592 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ui/gfx')
-rw-r--r-- | ui/gfx/font_render_params_linux.cc | 2 | ||||
-rw-r--r-- | ui/gfx/image/image_skia_operations.cc | 2 | ||||
-rw-r--r-- | ui/gfx/switches.cc | 26 | ||||
-rw-r--r-- | ui/gfx/switches.h | 20 |
4 files changed, 48 insertions, 2 deletions
diff --git a/ui/gfx/font_render_params_linux.cc b/ui/gfx/font_render_params_linux.cc index 2b32c7b..3e3e92a 100644 --- a/ui/gfx/font_render_params_linux.cc +++ b/ui/gfx/font_render_params_linux.cc @@ -11,7 +11,7 @@ #else #include <fontconfig/fontconfig.h> #include "base/command_line.h" -#include "ui/base/ui_base_switches.h" +#include "ui/gfx/switches.h" #endif namespace gfx { diff --git a/ui/gfx/image/image_skia_operations.cc b/ui/gfx/image/image_skia_operations.cc index 75848c3..878d9d2 100644 --- a/ui/gfx/image/image_skia_operations.cc +++ b/ui/gfx/image/image_skia_operations.cc @@ -9,7 +9,6 @@ #include "skia/ext/image_operations.h" #include "skia/ext/platform_canvas.h" #include "ui/base/layout.h" -#include "ui/base/ui_base_switches.h" #include "ui/gfx/canvas.h" #include "ui/gfx/image/canvas_image_source.h" #include "ui/gfx/image/image_skia.h" @@ -22,6 +21,7 @@ #include "ui/gfx/size_conversions.h" #include "ui/gfx/skbitmap_operations.h" #include "ui/gfx/skia_util.h" +#include "ui/gfx/switches.h" namespace gfx { namespace { diff --git a/ui/gfx/switches.cc b/ui/gfx/switches.cc new file mode 100644 index 0000000..f25ea9b --- /dev/null +++ b/ui/gfx/switches.cc @@ -0,0 +1,26 @@ +// Copyright 2012 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#include "ui/gfx/switches.h" + +namespace gfx { +namespace switches { + +// Whether or not ImageSkiaOperations methods can scale one of images +// if they don't have the same scale factor. +const char kDisableScalingInImageSkiaOperations[] = + "disable-scaling-in-image-skia-operations"; + +// Let text glyphs have X-positions that aren't snapped to the pixel grid in +// the browser UI. +const char kEnableBrowserTextSubpixelPositioning[] = + "enable-browser-text-subpixel-positioning"; + +// Enable text glyphs to have X-positions that aren't snapped to the pixel grid +// in webkit renderers. +const char kEnableWebkitTextSubpixelPositioning[] = + "enable-webkit-text-subpixel-positioning"; + +} // namespace switches +} // namespace gfx diff --git a/ui/gfx/switches.h b/ui/gfx/switches.h new file mode 100644 index 0000000..12f4efe --- /dev/null +++ b/ui/gfx/switches.h @@ -0,0 +1,20 @@ +// Copyright 2012 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#ifndef UI_GFX_SWITCHES_H_ +#define UI_GFX_SWITCHES_H_ + +#include "ui/base/ui_export.h" + +namespace gfx { +namespace switches { + +UI_EXPORT extern const char kDisableScalingInImageSkiaOperations[]; +UI_EXPORT extern const char kEnableBrowserTextSubpixelPositioning[]; +UI_EXPORT extern const char kEnableWebkitTextSubpixelPositioning[]; + +} // namespace switches +} // namespace gfx + +#endif // UI_GFX_SWITCHES_H_ |