summaryrefslogtreecommitdiffstats
path: root/app/gfx
Commit message (Collapse)AuthorAgeFilesLines
* Move base/gfx contents to gfx/ben@chromium.org2010-03-1413-15/+16
| | | | | | | | | TBR=darin BUG=none TEST=none git-svn-id: svn://svn.chromium.org/chrome/trunk/src@41559 0039d316-1c4b-4281-b951-d872f2087c98
* Create a toplevel gfx/ dir and seed it with icon_util.ben@chromium.org2010-03-133-945/+0
| | | | | | | | | | TBR=darin BUG=none TEST=none Review URL: http://codereview.chromium.org/915002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@41528 0039d316-1c4b-4281-b951-d872f2087c98
* Don't allocate temporary buffer during PNG encoding.erg@google.com2010-03-122-29/+105
| | | | | | | | | | | | | | | | | | PNGCodec::EncodeBGRASkBitmap() was originally designed for dealing with 16x16 pixel favicons. It allocated a temporary buffer to unpremultiply the rgb pixels in the incoming skia image. These days, it's used for any PNG<->SkBitmap task, including the theme system. In one case, I saw multiple 10 megabyte temporary buffers allocated and deallocated here. Instead, juggle the code a little to only allocate one row worth of pixels and to reuse that buffer. BUG=none TEST=Existing PNGCodec.* tests, plus PNGCodec.EncodeBGRASkBitmapDiscardTransparency Review URL: http://codereview.chromium.org/851006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@41493 0039d316-1c4b-4281-b951-d872f2087c98
* GTK: more browser action toolbar functionality. estade@chromium.org2010-03-121-0/+4
| | | | | | | | | | | | | | | | - Resize smartly after dragging (animate to the "right" size) - Add the overflow menu (it is clickable, but you can't drag to/from it) - Resize appropriately after adding/removing buttons still TODO: - persist the #icons that are visible BUG=32101 TEST=manual Review URL: http://codereview.chromium.org/897001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@41372 0039d316-1c4b-4281-b951-d872f2087c98
* Fix some issues with text size calculation and message boxes.pkasting@chromium.org2010-03-111-40/+54
| | | | | | | | | | | | | | First, size calculations for multi-line, character-breaking strings with no prespecified width were returning useless values, and when given pathological input, could take extremely long time. Second, the flag calculations for text layout were a bit odd. For example, we wouldn't add an ending ellipsis on elided text if it was multi-line, and we wouldn't add an ellipsis on a clipped word if character breaking was off. Fixed these and reordered the calculations to match the order in which the header declares the flags. Third, message boxes shouldn't need to trim their inputs, or add an ellipsis character, as both of these should now be handled safely by the underlying code. BUG=34721 TEST=alert("AAAAA") for strings of As that are, say, 4000 characters long should not cause the UI to hang up for noticeable lengths of time Review URL: http://codereview.chromium.org/810003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@41343 0039d316-1c4b-4281-b951-d872f2087c98
* svn prop fixes. Applied to all files not in third_party.pkasting@chromium.org2010-03-092-0/+0
| | | | | | | | | | | | * Removed eol-style, executable and mergeinfo from BMP/GIF/ICO/JPEG files, and set correct mime-type. * Removed executable and mergeinfo from .c/.cc/.cpp/.h/.m/.mm and .gyp files, and set eol-style to LF. TBR=evanm BUG=none TEST=none git-svn-id: svn://svn.chromium.org/chrome/trunk/src@40991 0039d316-1c4b-4281-b951-d872f2087c98
* app: string_util.h -> utf_string_conversions.h fix.jhawkins@chromium.org2010-03-064-10/+16
| | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/668226 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@40853 0039d316-1c4b-4281-b951-d872f2087c98
* Workaround for Pango integer overflow on really long strings.mmoss@google.com2010-03-011-0/+12
| | | | | | | | | This fixes TextEliderTest.ElideTextLongStrings breakage on "Linux Tests (dbg-shlib)(1)" (Karmic). http://chrome-buildbot.corp.google.com:8016/builders/Linux%20Tests%20(dbg-shlib)(1)/builds/1367/steps/app_unittests/logs/stdio Review URL: http://codereview.chromium.org/661244 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@40297 0039d316-1c4b-4281-b951-d872f2087c98
* Move skia_utils_gtk.cc/.h to app/gfx/. Original patch by Thiago Farina (see ↵pkasting@chromium.org2010-02-262-0/+54
| | | | | | | | | http://codereview.chromium.org/660063 ), r=me. BUG=22853 TEST=none git-svn-id: svn://svn.chromium.org/chrome/trunk/src@40083 0039d316-1c4b-4281-b951-d872f2087c98
* Remove ampersands from menu item titles. See http://crosbug.com/1273avayvod@chromium.org2010-02-131-8/+19
| | | | | | | | | | BUG=None TEST=Right click bookmark bar. See no & in Cut,Copy,Paste and Bookmark Manager. Review URL: http://codereview.chromium.org/593074 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38987 0039d316-1c4b-4281-b951-d872f2087c98
* Remove TODOs or add bug numbers to TODOspinkerton@chromium.org2010-02-121-1/+1
| | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/606016 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38892 0039d316-1c4b-4281-b951-d872f2087c98
* Make clicking on side tabs to select them work. ben@chromium.org2010-02-114-0/+86
| | | | | | | | | | | | Use a simple round rect for the visual treatment. Add some rect conversion utils. http://crbug.com/34509 TEST=none Review URL: http://codereview.chromium.org/597012 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38856 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 38828 - Make clicking on side tabs to select them work.ben@chromium.org2010-02-114-87/+0
| | | | | | | | | | | | | | Use a simple round rect for the visual treatment. Add some rect conversion utils. http://crbug.com/34509 TEST=none Review URL: http://codereview.chromium.org/597012 TBR=ben@chromium.org git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38834 0039d316-1c4b-4281-b951-d872f2087c98
* Make clicking on side tabs to select them work.ben@chromium.org2010-02-114-0/+87
| | | | | | | | | | | | Use a simple round rect for the visual treatment. Add some rect conversion utils. http://crbug.com/34509 TEST=none Review URL: http://codereview.chromium.org/597012 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38828 0039d316-1c4b-4281-b951-d872f2087c98
* Remove redundant casts in g_signal_connect() throughout all gtk code we have.erg@chromium.org2010-02-101-3/+1
| | | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/600033 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38629 0039d316-1c4b-4281-b951-d872f2087c98
* Tweak some things to be compatible with libpng 1.4.craig.schlenter@chromium.org2010-02-051-9/+4
| | | | | | | | | | | libpng 1.2 should still work too. BUG=32805 TEST=compiles on tryservers and locally against libpng 1.4 Review URL: http://codereview.chromium.org/569009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38188 0039d316-1c4b-4281-b951-d872f2087c98
* [GPU] Get GPU process running on the mackbr@google.com2010-02-031-2/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Initial port of GPU process / plugin to Mac OS X. Uses new IOSurface APIs and therefore currently runs only on 10.6. Alternate strategy will need to be devised for 10.5. Slight UI issues remain such as GPU plugins initially showing up in the wrong place on the page. These will be fixed in follow-on bugs. Minimal changes made to command buffer code to get it to compile on Mac OS X. Commented out use of nested anonymous namespaces in gles2_cmd_decoder.cc which were causing the linker to crash with a seg fault. Refactored gyp files so the OS test enabling the GPU plugin is in one place, common.gypi, and other files test only the variable enable_gpu. Slight change to gles2_demo_cc.cc to add some simple animation to verify that updates from the GPU plugin are reaching the screen. Changed Pepper test plugin to use 3D view by default and commented out use of audio context because of recent issues. TEST=none (ran Pepper Test Plugin with 3D view enabled) BUG=http://crbug.com/25988 Review URL: http://codereview.chromium.org/558035 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@37934 0039d316-1c4b-4281-b951-d872f2087c98
* WebKit roll 54045:54059pfeldman@chromium.org2010-01-291-2/+1
| | | | | | Review URL: http://codereview.chromium.org/553147 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@37513 0039d316-1c4b-4281-b951-d872f2087c98
* WebKit roll 54016:54045.pfeldman@chromium.org2010-01-291-1/+2
| | | | | | Review URL: http://codereview.chromium.org/551202 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@37503 0039d316-1c4b-4281-b951-d872f2087c98
* OpenBSD/FreeBSD ifdefs and GYP changes for app/ directorypvalchev@google.com2010-01-234-14/+12
| | | | | | | | | | | - Use OS_POSIX && !OS_MACOSX defines to capture Linux/*BSD as they have many similarities, use other defines instead of OS_LINUX where sensible. Based on original work by Sprewell and Ben Laurie on FreeBSD port Review URL: http://codereview.chromium.org/548126 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@36931 0039d316-1c4b-4281-b951-d872f2087c98
* Fix bad tooltip wrapping.davemoore@chromium.org2010-01-221-1/+15
| | | | | | | | | | Bug=32857 Test=Create a document with a long title. Open it. Hover over the tab title. Even if the text is elided it should be only 1 line tall. Review URL: http://codereview.chromium.org/543166 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@36869 0039d316-1c4b-4281-b951-d872f2087c98
* Attempt to fix text not being clipped. This only seems to happen insky@chromium.org2010-01-111-0/+3
| | | | | | | | | | | | certain configurations. I'm guessing the problem is because a width/height <= 0 is not honored and clipping doesn't happen. BUG=26483 TEST=none Review URL: http://codereview.chromium.org/542011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@35909 0039d316-1c4b-4281-b951-d872f2087c98
* Attempt to fix crash in issue 31082xiyuan@chromium.org2010-01-071-0/+4
| | | | | | | | | | | | | Crash in issue 31082 is inside Windows ICM (Image Color Management) code. I suspect it is caused by invalid bV5Intent value in the BITMAPV5HEADER we passed in. BUG=31082 TEST=Crashes in issue 31082 should be gone. Review URL: http://codereview.chromium.org/519081 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@35734 0039d316-1c4b-4281-b951-d872f2087c98
* Workaround bug in Pango that was resulted in incorrect wrapping.sky@chromium.org2010-01-041-0/+17
| | | | | | | | | BUG=30361 TEST=see bug Review URL: http://codereview.chromium.org/512002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@35490 0039d316-1c4b-4281-b951-d872f2087c98
* linux: reduce header interdependenciesevan@chromium.org2009-12-291-1/+1
| | | | | | | | | | | | By analyzing gcc -H output, I found some of our worst offenders for headers bringing in other headers. native_web_keyboard_event.h was responsible for just under 60,000 extra includes! This change will in theory make the build faster. Review URL: http://codereview.chromium.org/524004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@35326 0039d316-1c4b-4281-b951-d872f2087c98
* Init allocated SkBitmap pixelsxiyuan@chromium.org2009-12-171-0/+1
| | | | | | | | | | | | Init allocated pixels to ARGB(0,0,0,0) in CreateSkBitmapFromHICON per issue 30584. BUG=30584 TEST=wine-valgrind should no longer complain as in issue 30584. Review URL: http://codereview.chromium.org/504035 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@34852 0039d316-1c4b-4281-b951-d872f2087c98
* Add gfx::Insets::ToString().satorux@chromium.org2009-12-163-1/+90
| | | | | | | | | | | | | This will be useful for debugging views and views applications (I needed this when I was debugging my views application). Along the way, added tests for Insets. TEST=added tests; app_unittests; try BUG=none Review URL: http://codereview.chromium.org/497004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@34650 0039d316-1c4b-4281-b951-d872f2087c98
* Theme download status message, so that it's readable in themes of any color.mirandac@chromium.org2009-12-122-7/+10
| | | | | | | | BUG= 21176 TEST= Download something large in a dark or light theme. Note that status update (notification of how much data is left to download) is legible. Review URL: http://codereview.chromium.org/488002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@34395 0039d316-1c4b-4281-b951-d872f2087c98
* Fix a bug where some bitmaps were being tinted wrong. It turns outtony@chromium.org2009-12-112-3/+16
| | | | | | | | | | | | | that when converting from RGB to HSL we were comparing doubles and in on some CPUs, a register spill would cause us to do the conversion wrong. BUG=28243 Review URL: http://codereview.chromium.org/491036 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@34362 0039d316-1c4b-4281-b951-d872f2087c98
* Change most callers of NativeScrollbar size functions to use a dedicated ↵pkasting@chromium.org2009-12-092-0/+40
| | | | | | | | | | function that matches WebKit instead, since the callers really care about content area scrollbars. BUG=none TEST=none Review URL: http://codereview.chromium.org/463061 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@34177 0039d316-1c4b-4281-b951-d872f2087c98
* Fixes bug in textfield on views/gtk where we weren't properlysky@chromium.org2009-12-041-1/+17
| | | | | | | | | | | | | accounting for border size if not specified by style. Also changes button on views/gtk not to fix the pref height at 29. There is no reason for us to do this. BUG=none TEST=none Review URL: http://codereview.chromium.org/462036 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@33882 0039d316-1c4b-4281-b951-d872f2087c98
* Fixes bug where Chrome was not rendering fonts at the size it shouldsky@chromium.org2009-12-012-0/+24
| | | | | | | | | | | | have been. This was only apparent at DPIs other than the default, such as is typically seen on netbooks. BUG=none TEST=none Review URL: http://codereview.chromium.org/452031 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@33487 0039d316-1c4b-4281-b951-d872f2087c98
* Fix issue 7618xiyuan@chromium.org2009-11-252-18/+43
| | | | | | | | | | | | | Issue 7618 is caused by an all transparent favicon. When all pixels in XOR mask has alpha value of zero, Windows will use the AND mask. So create one for this case. BUG=7618 TEST=Verify fix for issue 7618. Review URL: http://codereview.chromium.org/434091 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@33149 0039d316-1c4b-4281-b951-d872f2087c98
* Re-enable TextEliderTest.ElideTextLongStrings.estade@chromium.org2009-11-202-3/+9
| | | | | | | | | | Pango returns 0 for absurdly long strings. Cut the text in half and try again if this occurs. BUG=15435 Review URL: http://codereview.chromium.org/414013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@32572 0039d316-1c4b-4281-b951-d872f2087c98
* Simplify some code that loops over all pixels of a bitmap.pkasting@chromium.org2009-11-191-32/+17
| | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/404033 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@32444 0039d316-1c4b-4281-b951-d872f2087c98
* Fix lint errors in app/ and turn on presubmit check.erg@google.com2009-11-173-6/+6
| | | | | | Review URL: http://codereview.chromium.org/400016 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@32222 0039d316-1c4b-4281-b951-d872f2087c98
* Added a flag to the Canvas class which allows forcing an RTL directionalityidana@chromium.org2009-11-112-5/+19
| | | | | | | | | | | | | on text drawn using Canvas::DrawStringInt(). Using this flag, it is possible to render RTL text correctly on platforms where LRE/PDF chars are not supported (e.g. Windows XP with no RTL fonts installed). BUG=23425 TEST=Run chrome and enter Hebrew text into the omnibox (see bug description). Make sure suggestions are formatted correctly. Verify in both RTL and LTR UIs. Review URL: http://codereview.chromium.org/384018 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@31619 0039d316-1c4b-4281-b951-d872f2087c98
* Unrevert 31478 Add UI for turning on/off network devices.mpcomplete@chromium.org2009-11-103-0/+106
| | | | | | | | | | | BUG=26636 TEST=run skbitmap_operations_unittest Review URL: http://codereview.chromium.org/353028 TBR=chocobo@google.com Review URL: http://codereview.chromium.org/384017 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@31598 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 31478 - Add UI for turning on/off network devices.mpcomplete@chromium.org2009-11-103-106/+0
| | | | | | | | | | | BUG=26636 TEST=run skbitmap_operations_unittest Review URL: http://codereview.chromium.org/353028 TBR=chocobo@google.com Review URL: http://codereview.chromium.org/384014 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@31589 0039d316-1c4b-4281-b951-d872f2087c98
* Add UI for turning on/off network devices.chocobo@google.com2009-11-093-0/+106
| | | | | | | | BUG=26636 TEST=run skbitmap_operations_unittest Review URL: http://codereview.chromium.org/353028 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@31478 0039d316-1c4b-4281-b951-d872f2087c98
* Fix various problems with inline autocomplete and URLs that change length ↵pkasting@chromium.org2009-11-071-5/+5
| | | | | | | | | | | | | | | | | | | | during fixup: * URLs with http auth info, which gets stripped * URLs with IDN hosts * URLs with escaped values that get unescaped In cases like these, we'd inline autocomplete from the wrong locations, highlight the wrong portions of the URL as matches, and sometimes DCHECK() in debug mode. The fix is to track how fixup affects the offsets into the URL we care about. Plumbing this required an enormous number of additions :( There is also a fix here to the URL Fixer Upper, which was obviously modified at some point in the past to use the Parsed components, but without updating the comments or some of the functionality to match. Since this isn't supposed to "fix up" things that aren't simple typos, I removed some code to "fix" bogus ports, which was causing bizarre effects when typing HTTP auth URLs ("http://foo:bar" would be fixed to "http://foo" and then matched for inline autocompletion, which was clearly wrong). This is tested incidentally by one of the new History URL Provider tests (which is how I discovered it). BUG=4010 TEST=Covered by unittests Review URL: http://codereview.chromium.org/372017 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@31352 0039d316-1c4b-4281-b951-d872f2087c98
* First patch in making destructors of refcounted objects private.jam@chromium.org2009-11-051-1/+4
| | | | | | | BUG=26749 Review URL: http://codereview.chromium.org/360042 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@31136 0039d316-1c4b-4281-b951-d872f2087c98
* Attempt 2 at:sky@chromium.org2009-11-045-17/+93
| | | | | | | | | | | | | | | Gets find bar animation/clipping to work on views/gtk. The only difference between this and the first version is fixing an include in extension_host that was triggering mac to build views, as well as an extraneous SetSlideDuration I had used for testing. BUG=none TEST=none TBR=ben Review URL: http://codereview.chromium.org/342116 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@30942 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 30903 - Gets find bar animation/clipping to work on views/gtk.sky@chromium.org2009-11-045-93/+17
| | | | | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/340077 TBR=sky@chromium.org git-svn-id: svn://svn.chromium.org/chrome/trunk/src@30913 0039d316-1c4b-4281-b951-d872f2087c98
* Gets find bar animation/clipping to work on views/gtk.sky@chromium.org2009-11-045-17/+93
| | | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/340077 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@30903 0039d316-1c4b-4281-b951-d872f2087c98
* Fixed font height on OS X. Also added some unittests.akalin@chromium.org2009-11-033-6/+12
| | | | | | | | | BUG=none TEST=trybots Review URL: http://codereview.chromium.org/351024 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@30891 0039d316-1c4b-4281-b951-d872f2087c98
* Fix up extension badge text drawing.estade@chromium.org2009-10-304-7/+11
| | | | | | | | | | | | | | | Fall abck to the system default font if the preferred font isn't available. Also, only create the SkPaint struct once, not on every paint. Also, make some more things const. BUG=25693 TEST=badge still looks good, that crash goes away Review URL: http://codereview.chromium.org/341045 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@30631 0039d316-1c4b-4281-b951-d872f2087c98
* Implemented most of HtmlDialogWindowController, which is a Cocoa portakalin@chromium.org2009-10-301-0/+3
| | | | | | | | | | | | | | | | | | | | of HtmlDialogView. Added TODO to fix inaccurate font height metric for OS X font class (and maybe width). Added the BrowserCommandExecutor protocol so that not just a BrowserWindowController can be the window controller for a ChromeEventProcessingWindow. Added unittests. Also tested manually with the bookmark sync setup wizard dialog. BUG=23073 TEST=added unittests, trybot, and manual testing Review URL: http://codereview.chromium.org/344008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@30619 0039d316-1c4b-4281-b951-d872f2087c98
* Problem clipping gtk text.davemoore@chromium.org2009-10-301-1/+1
| | | | | | | | | BUG=26266i TEST=NONE Review URL: http://codereview.chromium.org/342060 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@30604 0039d316-1c4b-4281-b951-d872f2087c98
* Got the about panel to have its text lined up correctly.davemoore@chromium.org2009-10-273-19/+101
| | | | | | | | Also added underline capability to linux fonts. Review URL: http://codereview.chromium.org/338029 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@30276 0039d316-1c4b-4281-b951-d872f2087c98