diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2015-11-10 10:28:29 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2015-11-10 10:32:00 +0100 |
commit | d3b6cb7ec2da4afb5687c9d28b2be2f96e6aa7b1 (patch) | |
tree | e9d209d6d5f06cacd8e0df78c7f6b8ad45d74be5 /vcl/source/glyphs/graphite_layout.cxx | |
parent | 45979047abbd9da7a29401f298e8ef9ab58ad337 (diff) |
loplugin:nullptr (automatic rewrite)
Change-Id: I05e89f9896170d4df3d1377549ea074f06b884a0
Diffstat (limited to 'vcl/source/glyphs/graphite_layout.cxx')
-rw-r--r-- | vcl/source/glyphs/graphite_layout.cxx | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/vcl/source/glyphs/graphite_layout.cxx b/vcl/source/glyphs/graphite_layout.cxx index eaff9713d316..d10538abcd9a 100644 --- a/vcl/source/glyphs/graphite_layout.cxx +++ b/vcl/source/glyphs/graphite_layout.cxx @@ -148,7 +148,7 @@ GraphiteLayout::fillFrom(gr_segment * pSegment, ImplLayoutArgs &rArgs, float fSc if (!nGlyphs || lastCharPos - mnSegCharOffset == 0) return; const gr_slot* baseSlot = bRtl ? gr_seg_last_slot(pSegment) : gr_seg_first_slot(pSegment); // find first base - while (baseSlot && gr_slot_attached_to(baseSlot) != NULL && !gr_slot_can_insert_before(baseSlot)) + while (baseSlot && gr_slot_attached_to(baseSlot) != nullptr && !gr_slot_can_insert_before(baseSlot)) baseSlot = bRtl ? gr_slot_prev_in_segment(baseSlot) : gr_slot_next_in_segment(baseSlot); assert(baseSlot); int nextChar = gr_cinfo_base(gr_seg_cinfo(pSegment, gr_slot_before(baseSlot))) + mnSegCharOffset; @@ -354,7 +354,7 @@ GraphiteLayout::append(gr_segment *pSeg, ImplLayoutArgs &rArgs, // Recursively append all the attached glyphs. float cOrigin = nextGlyphOrigin; - for (const gr_slot * agi = gr_slot_first_attachment(gi); agi != NULL; agi = gr_slot_next_sibling_attachment(agi)) + for (const gr_slot * agi = gr_slot_first_attachment(gi); agi != nullptr; agi = gr_slot_next_sibling_attachment(agi)) if (!gr_slot_can_insert_before(agi)) cOrigin = append(pSeg, rArgs, agi, cOrigin, nextGlyphOrigin, scaling, rDXOffset, false, baseChar, baseGlyph, bRtl); @@ -379,8 +379,8 @@ GraphiteLayout::~GraphiteLayout() throw() { clear(); // the features and font are owned by the platform layers - mpFeatures = NULL; - mpFont = NULL; + mpFeatures = nullptr; + mpFont = nullptr; } void GraphiteLayout::clear() @@ -436,11 +436,11 @@ bool GraphiteLayout::LayoutText(ImplLayoutArgs & rArgs) nBidiEndRunPos = minimum<int>(nLength, nBidiEndRunPos + EXTRA_CONTEXT_LENGTH); const sal_Unicode *pStr = rArgs.mrStr.getStr(); size_t numchars = gr_count_unicode_characters(gr_utf16, pStr + nBidiMinRunPos, - pStr + nBidiEndRunPos, NULL); - gr_segment * pSegment = gr_make_seg(mpFont, mpFace, 0, mpFeatures ? mpFeatures->values() : NULL, + pStr + nBidiEndRunPos, nullptr); + gr_segment * pSegment = gr_make_seg(mpFont, mpFace, 0, mpFeatures ? mpFeatures->values() : nullptr, gr_utf16, pStr + nBidiMinRunPos, numchars, 2 | int(bRightToLeft)); - if (pSegment != NULL) + if (pSegment != nullptr) { success = true; mnSegCharOffset = nBidiMinRunPos; |