summaryrefslogtreecommitdiff
path: root/vcl
AgeCommit message (Collapse)Author
2016-01-13Bin unused fieldTor Lillqvist
Change-Id: I664e3815bcdaff82a03309ae387154914471a80b
2016-01-13vcl: Create accessor and mutator for full stop centered in FontMetricChris Sherlock
Accessor and mutator created for full stop centered flag, removed bit field. See commit description in 8bfccd3a71d911b6d ("vcl: Create accessor and mutator for font scaling in FontMetric") for reasoning behind patch. Unit tests - check to ensure that can set full stop centered flag - check equality operator on FontMetric after setting full stop centered flag Change-Id: I9cacb0fbf9ea65cfebcaebdc9f0481c0a796cbcf Reviewed-on: https://gerrit.libreoffice.org/21413 Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com> Tested-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-13vcl: format enum in ImplFontMetric to make it easier to rebaseChris Sherlock
Change-Id: Ic2e7213254b60cf3c384dd7ab4696092dbbc5108 Reviewed-on: https://gerrit.libreoffice.org/21412 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-13vcl: Create accessor and mutator for font scaling in FontMetricChris Sherlock
This is fragile code! There are actually *two* classes that do almost precisely the same thing, they are: - ImplFontMetric, and - ImplFontMetricData They both have much in common, including their class name, and even most of their functionality. In fact, they both have common accessor functions. When I look at the code, it looks like OutputDevice is actually given an ImplFontMetricData object, which it then uses to populate an ImplFontMetric object... Basically, I'm going to merge these classes. To do so, I'm going to do the following: Step 1: Implement accessor functions for ImplFontMetric and FontMetric (then remove the friendship of this class to OutputDevice!) Step 2: Write a unit test for each accessor function in ImplFontMetric Step 3: Ensure that ImplFontMetric and ImplFontMetricData use some sort of smart pointer (probably an intrusive_ptr like I did ages ago with FontCharMap) Step 4: Merge the two classes together once their class interfaces are the same and I am satisfied they do the same thing Step 5: Find all instances of inefficient usage - for instance, I can do away with the code that copies the ImplFontMetricData attributes into an ImplFontMetric object. Change-Id: I07c1cb848774b130fa2ca60b51da53e07754dd00 Reviewed-on: https://gerrit.libreoffice.org/21399 Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com> Tested-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-12tdf#96385 - opengl: dynamically adjust priority of swap buffers.Michael Meeks
Initially we start with a very low priority, so that the lame bits of code that do eg. focus, and cursor rendering before the document is visible do not cause a swap, flash. Then after we've processed a REPAINT priority idle (hopefully our first paint) we adjust the swap priority to highest. Essentially a fusion of Tor's approach and mine. Change-Id: Ib9b78a18fb9359ac8c3dee1cfeb30177c08fe162 Reviewed-on: https://gerrit.libreoffice.org/21405 Reviewed-by: Tor Lillqvist <tml@collabora.com> Tested-by: Tor Lillqvist <tml@collabora.com>
2016-01-12Revert "Re-work focus handling to use an idle handler"Miklos Vajna
This reverts commit 0ba752201dca6129cc6b4a19ec93eb369eb70890. It breaks CppunitTest_desktop_lib on Linux.
2016-01-12Re-work focus handling to use an idle handlerTor Lillqvist
Gets rid of some flashing when using OpenGL. Change-Id: I1273b960725bf868e7340eac3f2bad2f20e73d91 Reviewed-on: https://gerrit.libreoffice.org/21390 Reviewed-by: Tor Lillqvist <tml@collabora.com> Tested-by: Tor Lillqvist <tml@collabora.com>
2016-01-12No need to name unused parametersTor Lillqvist
Change-Id: I982a67f1e5279aa18131f99f4a8ba5c5c2c005a7
2016-01-12provide autorelease pool to avoid leakingDouglas Mencken
fixes “Object ... autoreleased with no pool in place - just leaking” Change-Id: I8bb10adf779f57a9c7c9f1a38415d61e391d181e Reviewed-on: https://gerrit.libreoffice.org/21370 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tor Lillqvist <tml@collabora.com> Tested-by: Tor Lillqvist <tml@collabora.com>
2016-01-12vcl: resplit FontAttributes from ImplFontMetricDataChris Sherlock
The change I made in commit 7b974e056df3 ("vcl: merge ImplFontMetricData with ImplFontAttributes") was... ill-advised. For starters, there really needs to be this split as FontSelectPattern needs it, and PhysicalFontFace only requires the font attributes, not the metric data. So the merge was unfortunately, in my mind, a failure and I'm manually backing it out now. Change-Id: Iac38f0815f984541e2f55099c965376dd88eeb43 Reviewed-on: https://gerrit.libreoffice.org/21380 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-12vcl: change from Impl_Font to ImplFontChris Sherlock
Change-Id: I5edacec5c74398777ab0006c0d4e76d7d3050876 Reviewed-on: https://gerrit.libreoffice.org/21376 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-12vcl: put FontConfigFontOptions into Unix headerChris Sherlock
Change-Id: I7b326d8fc8d2b6ecd9642ba958015285d0929a44 Reviewed-on: https://gerrit.libreoffice.org/21341 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-12vcl: move fontcharmap.cxx to the font folderChris Sherlock
Change-Id: If764e87a90d57b473019ec96a1ef9026dc9675ae Reviewed-on: https://gerrit.libreoffice.org/21340 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-12vcl: tidyup file name impfont.cxx -> fontcharmap.cxxChris Sherlock
Change-Id: Ib2acc963704c7613e1d3bd1761b619ece1aef79f Reviewed-on: https://gerrit.libreoffice.org/21339 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-12vcl: split off ImplFontCharMap into it's own header fileChris Sherlock
Change-Id: I6173cd191cd771b1f030fa737617b1067278ee10 Reviewed-on: https://gerrit.libreoffice.org/21338 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-11tdf#96875 Make OS X native context menus compatibleMaxim Monastirsky
... with how framework::MenuBarManager works, following my work of converting context menus to use it instead of SfxPopupMenuManager (see tdf#93837). MenuBarManager sets menu item properties/select handler when the menu activates - in MenuBarManager::Activate, but it was never called for submenus. The solution is to adapt the menuNeedsUpdate delegate to call Menu::Activate. This makes submenu items work, but doesn't update their visual state (e.g. title). The reason is that AquaSalMenu::ShowNativePopupMenu is creating a copy of the NSMenu, so AquaSalMenu::SetItemText is modifying the wrong NSMenu instance. Another problem is that AquaSalMenu::ShowNativePopupMenu tries to removes (via removeUnusedItemsRunner function) all disabled items, but the correct state is set by MenuBarManager only when the menu activates. So we must handle disabled items only after MenuBarManager::Activate did its job. Turns out that we can just hide items in NSMenu instead of removing them, so no need to clone the NSMenu anymore. Change-Id: If0785b7f9d5f0ad98ced23585379039a51dc13bf Reviewed-on: https://gerrit.libreoffice.org/21374 Reviewed-by: Maxim Monastirsky <momonasmon@gmail.com> Tested-by: Maxim Monastirsky <momonasmon@gmail.com>
2016-01-11tdf#94831: Check for null mpReadAccess before first useMatúš Kukan
There was erroneously added code before check in 45e8e0fbee40f9a8d91f4c559c8bbb16dd7b3f36. Change-Id: Ie2e84cfc061097c25e5d799e9c388abd9724bd93
2016-01-11initialize new member variablesCaolán McNamara
Change-Id: I3839bc134b337ccb7cfdb2ee70524e4721c8f83c
2016-01-11loplugin:privatebase: Make various derivations publicStephan Bergmann
...assuming they were implicitly made private by accident rather than by design. (And private derivation can cause unexpected failure of dynamic_cast, cf. 63b67ab5cab8cf7576a68cabe5fb1a42c6ad800c "Use public derivation, and remove then-unnecessary downcasts.") Change-Id: Id821afba34fd2f155e30fac903567707e46d1fde
2016-01-11tdf#96888 Kill internal vcl dog-tags ..Ras-al-Ghul
Made pBorderWin a VclPtr Change-Id: I1869371b410276df2e7504b32617c2d1e2b6725f Reviewed-on: https://gerrit.libreoffice.org/21281 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
2016-01-11tdf#96655 - clear non-offscreen status bar controls before render.Michael Meeks
Change-Id: I02a85ae4572dc23df2157af1cf164a0f82701613 Reviewed-on: https://gerrit.libreoffice.org/21300 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2016-01-11tdf#96888 Kill internal vcl dog-tags ..Ras-al-Ghul
Added an assert statement and corrected a glaring error regarding clear() usage Change-Id: Icc8ce940a6f97570d37389530f9fd90890ae8055 Reviewed-on: https://gerrit.libreoffice.org/21280 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
2016-01-11Remove BitmapFilterStackBlur, which is unused...Stephan Bergmann
...ever since it got introduced with 28c61871e876e6a2cac47439f768504b1a4c94a0 "vcl: stack blur implementation + basic test & performance test" Change-Id: I78672cf74c24930df92121baecb9886df4382036
2016-01-11vcl: fix Android buildMiklos Vajna
Change-Id: I05ce4ddb4c933eb1100e3a3410cea27520072933
2016-01-11loplugin:staticmethodsStephan Bergmann
Change-Id: I15d48d69dd05de34f1b85896c2b143d6f17eeecb
2016-01-11vcl: move vcl/generic/app/ files to vcl/unx/generic/appChris Sherlock
These source files as all specific to Unix environments (not, however, OS X) and are not "generic" (i.e. used across all platforms). Change-Id: Idba1e9bbe14d8a4bb8e5dd2c2ad1dc75458da53c Reviewed-on: https://gerrit.libreoffice.org/21335 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-11vcl: move vcl/generic/print files to vcl/unx/generic/printChris Sherlock
These source files as all specific to Unix environments (not, however, OS X) and are not "generic" (i.e. used across all platforms). Change-Id: I6008a272c4b961a12702e2ef8727c56df9e80164 Reviewed-on: https://gerrit.libreoffice.org/21334 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-11vcl: move vcl/generic/fontmanager files to vcl/unx/generic/fontmanagerChris Sherlock
These source files as all specific to Unix environments (not, however, OS X) and are not "generic" (i.e. used across all platforms). Change-Id: I23650c86a7b74c2ac150b981e4be88eaea07e936 Reviewed-on: https://gerrit.libreoffice.org/21314 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-11vcl: rename adobeenc.tab to adobe_encoding_table.hxxChris Sherlock
Change-Id: Id7dbcd97acaf6a7deb13de2582c7a3515cedfac1 Reviewed-on: https://gerrit.libreoffice.org/21313 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-11PCH support on LinuxAshod Nakashian
Fixes and improvements to support Precompiled Headers on Linux. Change-Id: I8145c146b0dba56c7a4d0fdf9c330164b67ada53 Reviewed-on: https://gerrit.libreoffice.org/21307 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
2016-01-11vcl: move all glyph files from generic to unxChris Sherlock
All the files in glyph are only used by Unix based systems, with the exception of OS X. Therefore, it's not really "generic" as in "used across all platforms" but is generic as in "used in all Unix-based systems". Change-Id: Id89c09df74f0ddafee5c88c55bac4c35f9b23ef8 Reviewed-on: https://gerrit.libreoffice.org/21312 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-11vcl: rename gcach_ftyp.{cxx|hxx} to freetype_glyphcache.{cxx|hxx}Chris Sherlock
Change-Id: If17c0c36108c2437accba105e11a93a009d2c91f Reviewed-on: https://gerrit.libreoffice.org/21311 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-11vcl: move gcach_ftyp.cxx to vcl/unx/generic/glyphsChris Sherlock
Change-Id: Id12edc0660a2c22c6d04b820ad052bde4fa75143 Reviewed-on: https://gerrit.libreoffice.org/21310 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-10avoid crash on vcldemo bad indexCaolán McNamara
Change-Id: I3a778f41897da885ea039526e4701ebebfe57c4d
2016-01-10Fix typosAndrea Gelmini
Change-Id: I9a5940027423ff0791fa7da0b79b617412ce6b86 Reviewed-on: https://gerrit.libreoffice.org/21209 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
2016-01-10Cleanup FontCharMapPtr variable prefixesChris Sherlock
Change-Id: Ib106b91ab71ee45d5ad469d0beaf4ebaef8b57e1 Reviewed-on: https://gerrit.libreoffice.org/21306 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-10vcl: promote ImplFontAttributes to FontAttributesChris Sherlock
ImplFontAttributes is no longer merely a pImpl (or "compilation firewall", take your pick) but is a fully fledged class in its own right that is used by a number of classes, including FontSelectPattern, LogicalFontInstance and PhysicalFontFace. Thus I'm "promoting" the use of this class in the codebase. Change-Id: I26866080a64796978d1c25efbcd16e3e6f94aaa5 Reviewed-on: https://gerrit.libreoffice.org/21305 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-10vcl: add missing mutator operations to ImplFontAttributesChris Sherlock
Change-Id: I631114978ed6f23711502dd1b5f16e9e982265eb Reviewed-on: https://gerrit.libreoffice.org/21303 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-10vcl: Renamed ImplPdfBuiltinFontData to PdfBuiltinFontFaceChris Sherlock
Base class's name is PhysicalFontFace, which is used to create a logical font instance. Each platform (including the PDF writer it appears!) implements it's own factory function - so it's more than just a "data" class. I am also aiming to keep naming in the class heirachy consistent, thus the reason for the name change. Change-Id: Idb8c5b6a3b23a39ca727d355dcf421307cacbb2f Reviewed-on: https://gerrit.libreoffice.org/21302 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-10vcl: (OS X only) Change CoreTextFontData to CoreTextFontFaceChris Sherlock
The base class is called PhysicalFontFace (I believe it was called something like ImplFontData or somesuch before it was changed), and it is really primarily used to provide a factory function to create the logical font instance that LibreOffice can use (i.e. we distinguish between "physical" and "logical" fonts - as physical font is the actual font installed on the system, and the logical font is the one we ask for and have mapped to the physical font face). I also want to provide naming consistency in the class heirachy to enhance code readability, so that's another reason I've changed this class name. Change-Id: Ib7f23da1e3a1db59f4d04f5bb096f490e2958a4b Reviewed-on: https://gerrit.libreoffice.org/21299 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-10vcl: (Windows only) Changed ImplWinFontData name to WinFontFaceChris Sherlock
The base class name for WinFontFace is PhysicalFontFace, which gives the actual font installed on Windows (this is eventually mapped and realized into a LogicalFontInstance). However, PhysicalFontFace is not just a data structure, it also holds the function CreateFontInstance which must be implemented by the subclasses for each platform to allow fonts to be used in LibreOffice. Therefore, to keep the naming consistent I am following the lead of the base class and renaming ImplWinFontData to WinFontFace (and removing the "Impl" business, as this is not necessary). Change-Id: I4debb3af3ab5067b7e12e3659f2c71aba91e848c Reviewed-on: https://gerrit.libreoffice.org/21298 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-10vcl: (Windows only) Changed ImplWinFontEntry name to WinFontInstanceChris Sherlock
The base class is no longer called ImplFontEntry, but is now LogicalFontInstance. I want to bring the names in the class hierachy into line for consistency, so this change is necessary. Change-Id: Ie24197c140bf152f78ed7faf46b7509b82bcbdee Reviewed-on: https://gerrit.libreoffice.org/21297 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-09tdf#96550 - vcl opengl - fix BGR/RGB swap for some 8-bit icons.Michael Meeks
Change-Id: Ic71b8a94cabc392e7b83df70c1691de8f4c12b43
2016-01-09cppcheck: truncLongCastAssignmentCaolán McNamara
Change-Id: I55f684c0afb8b0d4ab4b749084a3ab7b66201bda
2016-01-09tdf#96888 Kill internal vcl dog-tags ...Ras-al-Ghul
Did some changes to toolbox.cxx file. Patch No. 19 Change-Id: Ia66d208230c8ffeca095af60b311510a826321d8 Reviewed-on: https://gerrit.libreoffice.org/21236 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2016-01-09tdf#96888 Kill internal vcl dog-tags ..Ras-al-Ghul
Deleted a couple of clear statements Change-Id: I6ca2c565842e1b33b3e52724981f95b634e94263 Reviewed-on: https://gerrit.libreoffice.org/21275 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
2016-01-09tdf#96657 - vcl opengl: implement invert: Track Frame.Michael Meeks
Change-Id: I422ea8cfb8a81cca36203d496b92e15ea5b449d2 Reviewed-on: https://gerrit.libreoffice.org/21291 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2016-01-09tdf#96657 - vcldemo - implement invert: Track Frame rendering test.Michael Meeks
Change-Id: I07f4622945cf5787102317cfa38875c67104f265 Reviewed-on: https://gerrit.libreoffice.org/21290 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2016-01-09try and fix android buildCaolán McNamara
post... commit 86d06c9102d6f59946d7fbfdee5bb40e9a6d0fc6 Author: Chris Sherlock <chris.sherlock79@gmail.com> Date: Sat Jan 9 14:41:15 2016 +1100 vcl: move some Freetype stuff away from the "generic" folder I'm not adverse to simply moving these files into the "headless" dir to further untangle this Change-Id: Ib0c697b3d829baa92195d29983d39406bb72fce8
2016-01-09WaE: C4702: unreachable codeCaolán McNamara
regression from... commit 31bc9a228ed02dfa082e3a59c20b0ce106d5c75c Date: Sat Jan 9 03:09:49 2016 +0530 tdf#96888 Kill internal vcl dog-tags ... Change-Id: I3fb375701cd1f8d8d0ea7f8a22b727881eaf90eb