Takeshi Abe
d6a7f7fe98
starmath: Prefix n to SmCaretPos's Index
...
Change-Id: Ie1647d8143c4c38ebcf5111bffc291c26704c4c0
Reviewed-on: https://gerrit.libreoffice.org/32428
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp >
2016-12-26 12:17:13 +00:00
Takeshi Abe
074f0ab1d7
tdf#76296 Import MathML's <mspace>
...
as possibly multiple "~" and/or "`" by honoring its width attribute.
Change-Id: I17e361c3f8f5d061c856b72266332369497d16b9
Reviewed-on: https://gerrit.libreoffice.org/30809
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp >
2016-11-15 00:27:30 +00:00
Takeshi Abe
c966bac490
starmath: Drop unused 1st argument of SmErrorNode's ctor
...
Change-Id: I01d8fa4bcfbfd4757230ff54902967f709216111
Reviewed-on: https://gerrit.libreoffice.org/28678
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Caolán McNamara <caolanm@redhat.com >
Tested-by: Caolán McNamara <caolanm@redhat.com >
2016-09-06 07:32:24 +00:00
Takeshi Abe
ecafca50e9
Replace use of our own SmNodeIterator with range-based for loop
...
in starmath/source/cursor.cxx and starmath/qa/cppunit/mock-visitor.hxx.
Change-Id: I7733d5d17bb03532d6c4f1d6967c69d65bc3bede
Reviewed-on: https://gerrit.libreoffice.org/28538
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp >
2016-08-31 09:41:15 +00:00
Takeshi Abe
e04bea2bad
SmCursor::FindTopMostNodeInLine() requires non-null argument
...
Change-Id: I3643c8a299276d7f3568747e6428ced4c8a6e2bf
Reviewed-on: https://gerrit.libreoffice.org/28345
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp >
2016-08-24 06:57:54 +00:00
Takeshi Abe
8a5c2586dc
starmath: Do SmCursor::MoveTo() more simply
...
... without unnecessary copy and re-calculation of squared distances.
Change-Id: I2900f8ef690cae750be036dcb3c4270c82286a4c
2016-08-22 11:14:43 +09:00
Takeshi Abe
ddeb13b497
starmath: Use SmCaretPos::GetPosAfter()
...
Change-Id: Ie05354f9e359b9dbc10f9d8ee8a9579c67ec5e5f
Reviewed-on: https://gerrit.libreoffice.org/28185
Reviewed-by: Caolán McNamara <caolanm@redhat.com >
Tested-by: Caolán McNamara <caolanm@redhat.com >
2016-08-18 07:34:02 +00:00
Takeshi Abe
f36406bf44
starmath: Avoid assigned but unused value
...
Change-Id: I3d8ede40e2231e3b88c43b17e353ea962e02acc7
2016-08-17 14:45:07 +09:00
Noel Grandin
938821fb08
new loplugin overrideparam
...
verify that parameters on override methods have the same set of default
values for their params as their parent/super-methods do.
Change-Id: Ibdbc1c6e417fbaa680ea025a6bbf5ba9c2e5bcd2
Reviewed-on: https://gerrit.libreoffice.org/27437
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Noel Grandin <noelgrandin@gmail.com >
2016-07-25 06:09:17 +00:00
Takeshi Abe
f045d14791
starmath: Return early if the cursor locates after a text node
...
No longer create unnecessary copy of nodes.
Change-Id: Icf8cdd3ce0f9ebbf7159e9e7eaea7abe52c05060
Reviewed-on: https://gerrit.libreoffice.org/27366
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp >
2016-07-22 00:47:25 +00:00
Takeshi Abe
1eb533a045
starmath: Make AdjustFontDesc() precede Prepare()
...
because what Prepare() does depends on both nFontDesc and token
of the SmTextNode.
Change-Id: Ib7f8c408eb8f95a10f27ccbd3d80cdd0d6ea6d56
Reviewed-on: https://gerrit.libreoffice.org/27210
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp >
2016-07-15 07:56:39 +00:00
Takeshi Abe
a9d273ed8e
starmath: Prefer assert to SAL_WARN here
...
as defined enum cases are exhausted.
Change-Id: I6564cc0cd64d593f6aa02f0651ecb490bf7845bd
Reviewed-on: https://gerrit.libreoffice.org/27081
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp >
2016-07-11 09:59:38 +00:00
Takeshi Abe
1fc4af8695
Pass it by const ref
...
Change-Id: I0c2b48a503e2501210af690f02858dade994a733
Reviewed-on: https://gerrit.libreoffice.org/26048
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp >
2016-06-10 03:34:52 +00:00
Takeshi Abe
013f9d5aaa
Null pointer dereferences must not happen
...
This is a follow-up of 09981cd638
.
Inspired by coverity#1362478 etc.
Change-Id: If5507c52552393cccbb255cbf4b7e9f4b80db917
Reviewed-on: https://gerrit.libreoffice.org/25840
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Michael Stahl <mstahl@redhat.com >
2016-06-03 11:01:09 +00:00
Caolán McNamara
31038459b5
coverity#1362478 Explicit null dereferenced
...
and
coverity#1362479, coverity#1362480, coverity#1362481,
coverity#1362482, coverity#1362483, coverity#1362485
Change-Id: Ia3a32b69bcbe5ac3e7cc50dacfa02e8bf1aab787
2016-06-02 15:24:57 +01:00
Takeshi Abe
09981cd638
Use std::vector for SmCaretPosGraph
...
instead of employing ad hoc linked list and its iterator.
Change-Id: Ibc4709a2e67aa805cf54117303c47d9a8a5eede9
Reviewed-on: https://gerrit.libreoffice.org/25699
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Michael Stahl <mstahl@redhat.com >
2016-05-31 16:15:30 +00:00
Takeshi Abe
27ae0020d7
Prefix SmDocShell's members
...
as well as remaning aInterpreter to maParser.
Change-Id: I5f86737ffe05be981477e9dc65d433de0e1d5378
Reviewed-on: https://gerrit.libreoffice.org/25650
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp >
2016-05-31 01:14:40 +00:00
Takeshi Abe
f5ea7c09c8
starmath: nodes in the clipboard are owened by SmClipboard
...
This also omits the bIsOnlyIfSelected parameter for former
CloneLineToList(), which was true at its sole call site.
Change-Id: Idb71323f68f13ecc90d430ec8e18e0eef766ae4b
Reviewed-on: https://gerrit.libreoffice.org/25444
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp >
2016-05-26 02:22:54 +00:00
Takeshi Abe
4ab3149381
starmath: Fix missing call of AnnotationSelection() for SmCursor::Copy
...
... with unit tests of Copy/Cut/Paste.
Change-Id: I74dd6f235b52ef2c1388ea0d15d32af0fb30b2c8
Reviewed-on: https://gerrit.libreoffice.org/25362
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp >
2016-05-24 00:40:36 +00:00
Takeshi Abe
da68f03bb6
starmath: This should be an assert()
...
Change-Id: Ia8dd75512168fd0775a8019fc514627a7353b056
Reviewed-on: https://gerrit.libreoffice.org/25231
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp >
2016-05-23 04:38:04 +00:00
Noel Grandin
cc1a0ba927
convert TG constants to scoped enum
...
Change-Id: Ide719e8bb0d5aacc8d5da18f385b6373c7e48184
Reviewed-on: https://gerrit.libreoffice.org/24973
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp >
2016-05-17 02:28:25 +00:00
Takeshi Abe
c6883d467c
Fix typo
...
Change-Id: Ib8e891f3af7a9de87c54bc65be98d94a16545d71
2016-05-02 15:49:47 +09:00
Takeshi Abe
1ef1ed40cb
starmath: Drop unnecessary cast
...
Change-Id: Ia892100507de7365bcecfa0708f76931f84d797b
Reviewed-on: https://gerrit.libreoffice.org/24389
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp >
2016-04-27 02:58:02 +00:00
Noel Grandin
e8fd5a07ec
update loplugin stylepolice to check local pointers vars
...
are actually pointer vars.
Also convert from regex to normal code, so we can enable this
plugin all the time.
Change-Id: Ie36a25ecba61c18f99c77c77646d6459a443cbd1
Reviewed-on: https://gerrit.libreoffice.org/24391
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Noel Grandin <noelgrandin@gmail.com >
2016-04-26 10:55:58 +00:00
Noel Grandin
b4e3f5e9a7
loplugin:constantparam in starmath
...
Change-Id: I7a1b83ec51565f56b07ae77177e064c04f703d5f
2016-03-23 09:13:13 +02:00
Takeshi Abe
1de73e4ddf
starmath: Drop SmNode::FindIndex
...
Its sole usage can be replaced with SmNode::IndexOfSubNode.
Change-Id: Icfd4a3fe846b585c5fa3f47e0768729aba66d73e
Reviewed-on: https://gerrit.libreoffice.org/23064
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Caolán McNamara <caolanm@redhat.com >
Tested-by: Caolán McNamara <caolanm@redhat.com >
2016-03-09 16:22:17 +00:00
Noel Grandin
08e14eb270
loplugin:unuseddefaultparam in starmath
...
Change-Id: I740d931c0236c1a4d40013b458f249692695d6e5
2016-03-01 12:48:50 +02:00
Takeshi Abe
4753d78cf9
starmath: Assert that a parent always finds its child
...
Change-Id: I6cb75e0d62141dba2809aaec62761cedd8c3257a
Reviewed-on: https://gerrit.libreoffice.org/20733
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Kohei Yoshida <libreoffice@kohei.us >
2015-12-23 00:39:56 +00:00
Stephan Bergmann
374b4f349f
loplugin:nullptr (automatic rewrite)
...
Change-Id: Ife1eef04d905f12308b64b971176c2f045a1b268
2015-11-10 10:31:41 +01:00
Takeshi Abe
ce924d97aa
starmath: Represent ownership by std::unique_ptr
...
Change-Id: I7ce39cbdc0199d3508e7d16d1ce0b78f8d8ca620
Reviewed-on: https://gerrit.libreoffice.org/19230
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Noel Grandin <noelgrandin@gmail.com >
2015-10-08 06:21:15 +00:00
Takeshi Abe
867fcf48d5
starmath: Prefix members of SmCursor
...
Change-Id: Ib3407b5457f4d69294c95879455553dc013cc340
Reviewed-on: https://gerrit.libreoffice.org/19186
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Noel Grandin <noelgrandin@gmail.com >
2015-10-07 06:39:04 +00:00
Andrea Gelmini
7319f5facc
Fix typos
...
Change-Id: Ic3d2171521e308261c354d8f699b44b26c95f1ea
Reviewed-on: https://gerrit.libreoffice.org/18978
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de >
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de >
2015-09-30 10:45:48 +00:00
Noel Grandin
7d769f9df5
loplugin: defaultparams
...
Change-Id: Ibf0ea539d2a95073a12f84964759d9c7a94baa7b
2015-08-20 13:52:17 +02:00
Andrea Gelmini
1a8915ef83
Fix typos
...
Change-Id: I1c5e4970d4e90bdea68a901294594104de5e189e
Reviewed-on: https://gerrit.libreoffice.org/16582
Tested-by: Jenkins <ci@libreoffice.org >
Reviewed-by: Andras Timar <andras.timar@collabora.com >
2015-06-30 15:57:12 +00:00
Andrea Gelmini
9b7e1bf43d
Fix typos
...
Change-Id: Ieaf67cf597e05dbae5affa153af907fda4462a41
Reviewed-on: https://gerrit.libreoffice.org/16295
Reviewed-by: Michael Stahl <mstahl@redhat.com >
Tested-by: Michael Stahl <mstahl@redhat.com >
2015-06-16 10:59:53 +00:00
Noel Grandin
89dd3f8068
convert SfxObjectCreateMode to scoped enum
...
and fix some dodgy usage in /sc in the process
Change-Id: Ia2bee267df31aba431fc8cb81195bb83e5b64deb
2015-04-10 09:48:06 +02:00
Julien Nabet
aa1b4a294d
Various typos
...
Change-Id: I61d6a92e5301e07c9180d94dafec23ef1a06e0ef
2015-02-21 14:45:35 +01:00
Caolán McNamara
39611d6020
coverity#1267649 Logically dead code
...
and
coverity#1267645 Logically dead code
coverity#1267651 Logically dead code
Change-Id: If92e17708576bf11cefc28f903a24ad271b826c8
2015-02-11 12:00:03 +00:00
Caolán McNamara
f191139bce
coverity#1266461 Improper use of negative value
...
Change-Id: I4f78617129de21f7088d6f0d8b781674faa6b45a
2015-01-26 12:14:37 +00:00
Noel Grandin
0b30d5344c
loplugin: cstylecast
...
Change-Id: I759f55218538c8d39018626f14e78cd56341d44b
2014-12-03 10:43:53 +02:00
Takeshi Abe
c1358e5dc8
separate parse.hxx into smaller parts
...
... so that node.hxx no longer needs to include parse.hxx.
Change-Id: Iac1e21c208e3f0e3fd8ece16eee345e81574a0aa
2014-11-09 00:27:01 +09:00
Caolán McNamara
ed75dbb1ca
coverity#736100 Improper use of negative value
...
Change-Id: Ia5cf36b64841f2d465c922da40008a540cc6caf7
2014-05-11 21:05:55 +01:00
Caolán McNamara
70ba0a8d4e
coverity#736101 Improper use of negative value
...
Change-Id: I6fec141e19de921128365da7cbd17e0a0bc0b9a9
2014-05-11 21:05:55 +01:00
Caolán McNamara
08fad277a0
coverity#736102 Improper use of negative value
...
Change-Id: I3f915ff949fa00357599e8cfc59c01c6eb04e9fd
2014-05-11 21:05:54 +01:00
Thomas Arnhold
2805ac13dc
typo: choosen -> chosen
2014-04-14 12:32:02 +02:00
Tor Lillqvist
6835d9f307
It's "its", not "it's"
...
Change-Id: Ieaa787afd7cc622b4750a2ee8f17f6dad934ba63
2014-04-10 20:22:50 +03:00
Thomas Arnhold
d2dbab23ca
typo: horizontial -> horizontal
2014-03-29 19:16:29 +01:00
Caolán McNamara
46c95fa740
coverity#736099 Improper use of negative value
...
Change-Id: I065a8074fcafba123898c70eded464aa108e2e9e
2014-03-21 08:54:43 +00:00
Noel Grandin
ac01de882d
sfx2: sal_Bool->bool
...
Change-Id: I87c5a180566e9da185c2992844e6522e82c17747
2014-03-18 11:27:38 +02:00
Noel Grandin
86a32589e9
Find places where OUString and OString are passed by value.
...
It's not very efficient, because we generally end up copying it twice -
once into the parameter and again into the destination OUString.
So I create a clang plugin that finds such places and generates a
warning so that we can convert them to pass-by-reference.
Change-Id: I5341a6ea9e3190f4b4c05c42c85595e3dcd83361
2014-03-18 08:32:26 +02:00