Home
last modified time | relevance | path

Searched refs:textRect (Results 1 – 25 of 34) sorted by relevance

12

/ohos5.0/foundation/arkui/ui_lite/frameworks/components/
H A Dui_label_button.cpp31 Rect textRect = GetContentRect(); in OnDraw() local
32 textRect.SetLeft(textRect.GetLeft() + offset_.x); in OnDraw()
33 textRect.SetTop(textRect.GetTop() + offset_.y); in OnDraw()
35 labelButtonText_->ReMeasureTextSize(textRect, labelStyle_); in OnDraw()
37 uint16_t ellipsisIndex = labelButtonText_->GetEllipsisIndex(textRect, labelStyle_); in OnDraw()
38 labelButtonText_->OnDraw(gfxDstBuffer, invalidatedArea, GetOrigRect(), textRect, 0, in OnDraw()
H A Dui_arc_label.cpp307 Rect textRect = in ReMeasure() local
310 int16_t arcTextWidth = textRect.GetWidth(); in ReMeasure()
311 int16_t arcTextHeight = textRect.GetHeight(); in ReMeasure()
314 SetPosition(textRect.GetX(), textRect.GetY()); in ReMeasure()
H A Dui_canvas.cpp1462 Rect invalidRect = textRect; in BlitMapBuffer()
1463 transMap.SetTransMapRect(textRect); in BlitMapBuffer()
1504 Rect textRect = invalidatedArea; in DoDrawText() local
1506 textRect.SetPosition(start.x, start.y); in DoDrawText()
1512 text->ReMeasureTextSize(textRect, drawStyle); in DoDrawText()
1516 textRect.SetWidth(text->GetTextSize().x + 1); in DoDrawText()
1517 textRect.SetHeight(text->GetTextSize().y + 1); in DoDrawText()
1520 Rect textImageRect(0, 0, textRect.GetWidth(), textRect.GetHeight()); in DoDrawText()
1525 trans.SetTransMapRect(textRect); in DoDrawText()
1531 BlitMapBuffer(gfxDstBuffer, *mapBufferInfo, textRect, trans, invalidatedArea); in DoDrawText()
[all …]
/ohos5.0/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/text_field/
H A Dtext_select_controller.cpp128 auto textRect = textFiled->GetTextRect(); in CalcCaretMetricsByPosition() local
197 auto offset = localOffset - Offset(textRect.GetX(), textRect.GetY()); in ConvertTouchOffsetToPosition()
213 touchLocalOffset.SetX(textField->IsLTRLayout() ? textRect.Right() : textRect.Left()); in UpdateSelectByOffset()
216 touchLocalOffset.SetX(textField->IsLTRLayout() ? textRect.Left() : textRect.Right()); in UpdateSelectByOffset()
422 textRect.SetOffset(OffsetF(textRect.GetX(), textRect.GetY() + dy)); in MoveHandleToContentRect()
426 textRect.SetOffset(OffsetF(textRect.GetX(), textRect.GetY() - dy)); in MoveHandleToContentRect()
435 textRect.SetOffset(OffsetF(textRect.GetX() + dx, textRect.GetY())); in MoveHandleToContentRect()
439 textRect.SetOffset(OffsetF(textRect.GetX() - dx, textRect.GetY())); in MoveHandleToContentRect()
443 textFiled->SetTextRect(textRect); in MoveHandleToContentRect()
821 auto offset = localOffset - Offset(textRect.GetX(), textRect.GetY()); in IsTouchAtLineEnd()
[all …]
H A Dtext_input_ai_checker.cpp54 … InputAIChecker::IsMultiClickAtBoundary(const NG::OffsetF& handleOffset, const NG::RectF& textRect) in IsMultiClickAtBoundary() argument
56 if (textRect.GetX() - FLOAT_DIFF_COMPARE <= handleOffset.GetX() && in IsMultiClickAtBoundary()
57 handleOffset.GetX() <= textRect.GetX() + FLOAT_DIFF_COMPARE) { in IsMultiClickAtBoundary()
59 handleOffset.GetX(), textRect.GetX()); in IsMultiClickAtBoundary()
63 auto edge = textRect.GetX() + textRect.Width(); in IsMultiClickAtBoundary()
H A Dtext_field_overlay_modifier.cpp205 auto textRect = textFieldPattern->GetTextRect(); in PaintSelection() local
222 …vas.DrawRect(RSRect(textBox.Left() + (isTextArea ? contentOffset_->Get().GetX() : textRect.GetX()), in PaintSelection()
224 ? (textBox.Top() + (isTextArea ? textRect.GetY() : contentOffset_->Get().GetY())) in PaintSelection()
226 textBox.Right() + (isTextArea ? contentOffset_->Get().GetX() : textRect.GetX()), in PaintSelection()
228 ? (textBox.Bottom() + (isTextArea ? textRect.GetY() : contentOffset_->Get().GetY())) in PaintSelection()
315 auto textRect = textFieldPattern->GetTextRect(); in PaintPreviewTextDecoration() local
318 float offsetX = isTextArea ? contentOffset_->Get().GetX() : textRect.GetX(); in PaintPreviewTextDecoration()
319 float offsetY = isTextArea ? textRect.GetY() : contentOffset_->Get().GetY(); in PaintPreviewTextDecoration()
H A Dtext_field_select_overlay.cpp324 auto textRect = pattern->GetTextRect(); in GetSelectArea() local
325 res = MergeSelectedBoxes(selectRects, contentRect, textRect, textPaintOffset); in GetSelectArea()
380 auto textRect = pattern->GetTextRect(); in GetTextAreaCaretPosition() local
384 …offset = Offset(localOffset.GetX() - paddingLeft, localOffset.GetY() - textRect.GetY() - lineHeigh… in GetTextAreaCaretPosition()
386 …offset = Offset(localOffset.GetX() - paddingLeft, localOffset.GetY() - textRect.GetY() + lineHeigh… in GetTextAreaCaretPosition()
388 offset = Offset(localOffset.GetX() - paddingLeft, localOffset.GetY() - textRect.GetY()); in GetTextAreaCaretPosition()
H A Dtext_field_overlay_modifier.h66 void SetTextRect(const RectF& textRect) in SetTextRect() argument
68 textRect_ = textRect; in SetTextRect()
H A Dtext_input_ai_checker.h36 static bool IsMultiClickAtBoundary(const NG::OffsetF& handleOffset, const NG::RectF& textRect);
/ohos5.0/foundation/arkui/ui_lite/frameworks/common/
H A Dtext.cpp247 const Rect& textRect, in OnDraw() argument
258 if (mask.Intersect(mask, textRect)) { in OnDraw()
391 yOffset = textRect.GetHeight() - textHeight; in TextPositionY()
394 return textRect.GetY() + yOffset; in TextPositionY()
400 int16_t rectWidth = textRect.GetWidth(); in LineStartPos()
408 return textRect.GetX() + xOffset; in LineStartPos()
489 if (textSize_.y <= textRect.GetHeight()) { in GetEllipsisIndex()
495 p.x = textRect.GetWidth() - letterWidth; in GetEllipsisIndex()
496 p.y = textRect.GetHeight(); in GetEllipsisIndex()
507 return GetLetterIndexByPosition(textRect, style, p); in GetEllipsisIndex()
[all …]
/ohos5.0/foundation/arkui/ui_lite/interfaces/kits/common/
H A Dtext.h369 virtual void ReMeasureTextSize(const Rect& textRect, const Style& style);
371 …void ReMeasureTextWidthInEllipsisMode(const Rect& textRect, const Style& style, uint16_t ellipsisI…
376 const Rect& textRect,
446 uint16_t GetEllipsisIndex(const Rect& textRect, const Style& style);
526 virtual uint16_t GetPosXByLetterIndex(const Rect& textRect, const Style& style,
554 virtual uint16_t GetNextCharacterFullDispalyOffset(const Rect& textRect,
584 …virtual uint16_t GetLetterIndexByPosition(const Rect& textRect, const Style& style, const Point& p…
595 int16_t TextPositionY(const Rect& textRect, int16_t textHeight);
596 int16_t LineStartPos(const Rect& textRect, uint16_t lineWidth);
/ohos5.0/foundation/arkui/ace_engine/test/unittest/core/pattern/text_input/
H A Dtext_input_update_test.cpp454 RectF textRect = RectF(0.0f, 0.0f, 800.0f, 60.0f); variable
455 pattern_->SetTextRect(textRect);
492 pattern_->SetTextRect(textRect);
758 RectF textRect = RectF(0.0f, 0.0f, 0.0f, 0.0f); variable
759 pattern_->UpdateRectByTextAlign(textRect);
779 RectF textRect = RectF(0.0f, 0.0f, 0.0f, 0.0f); variable
780 pattern_->UpdateRectByTextAlign(textRect);
800 RectF textRect = RectF(0.0f, 0.0f, 0.0f, 0.0f); variable
801 pattern_->UpdateRectByTextAlign(textRect);
821 RectF textRect = RectF(0.0f, 0.0f, 0.0f, 0.0f); variable
[all …]
H A Dtext_field_content_modifier_test.cpp84 RectF textRect(DEFAULT_RECT_X, DEFAULT_RECT_Y, DEFAULT_RECT_WIDTH, DEFAULT_RECT_HEIGHT);
139 RectF textRect(DEFAULT_RECT_X, DEFAULT_RECT_Y, DEFAULT_RECT_WIDTH, DEFAULT_RECT_HEIGHT);
140 pattern_->SetTextRect(textRect);
/ohos5.0/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/text_area/
H A Dtext_area_layout_algorithm.cpp198 auto textRect = textRect_.GetSize(); in Layout() local
199 if (LessOrEqual(textRect.Height(), 0.0)) { in Layout()
200 textRect.SetHeight(content->GetRect().Height()); in Layout()
202 OffsetF textRectOffSet = Alignment::GetAlignPosition(size, textRect, align); in Layout()
/ohos5.0/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/calendar/
H A Dcalendar_paint_method.cpp78 …canvas, const std::string& text, const RSTextStyle& textStyle, const Rect& boxRect, Rect& textRect) in DrawCalendarText() argument
99textRect.SetRect(offset.GetX() + textPaintOffsetX, offset.GetY() + textPaintOffsetY, textWidth, te… in DrawCalendarText()
104 Rect textRect; in DrawCalendarText() local
105 DrawCalendarText(canvas, text, textStyle, boxRect, textRect); in DrawCalendarText()
489 Rect textRect; in PaintDay() local
493 DrawCalendarText(&canvas, dayStr, textStyle, boxRect, textRect); in PaintDay()
498 … boxRect = { textRect.GetOffset().GetX() + textRect.Width() - workStateHorizontalMovingDistance_, in PaintDay()
499textRect.GetOffset().GetY() + textRect.Height() - workStateVerticalMovingDistance_, workStateWidth… in PaintDay()
/ohos5.0/foundation/arkui/ace_engine/frameworks/core/components/calendar/
H A Drosen_render_calendar.cpp70 …vas, const std::string& text, const txt::TextStyle& textStyle, const Rect& boxRect, Rect& textRect) in GetTextParagraph() argument
78 const std::string& text, const txt::TextStyle& textStyle, const Rect& boxRect, Rect& textRect) in GetTextParagraph()
81 const std::string& text, const Rosen::TextStyle& textStyle, const Rect& boxRect, Rect& textRect) in GetTextParagraph()
106textRect.SetRect(offset.GetX() + textPaintOffsetX, offset.GetY() + textPaintOffsetY, textWidth, te… in GetTextParagraph()
125 Rect textRect; in GetTextParagraph() local
126 DrawCalendarText(canvas, text, textStyle, boxRect, textRect); in GetTextParagraph()
441 Rect textRect; in PaintDay() local
472 DrawCalendarText(canvas, day.dayMarkValue, workStateStyle, boxRect, textRect); in PaintDay()
481 DrawCalendarText(canvas, dayStr, textStyle, boxRect, textRect); in PaintDay()
493 … boxRect = { textRect.GetOffset().GetX() + textRect.Width() - workStateHorizontalMovingDistance_, in PaintDay()
[all …]
/ohos5.0/foundation/graphic/graphic_2d/rosen/test/2d_engine/unittest/rosen_text/adapter/skia_txt/
H A Dconvert_test.cpp76 TextRect textRect = AdapterTxt::Convert(box); variable
77 EXPECT_EQ(textRect.direction == TextDirection::RTL, true);
/ohos5.0/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/text_drag/
H A Dtext_drag_pattern.h54 …TextDragData(RectF textRect, float frameWidth, float frameHeight, float lineHeight, float lastLine… in TextDragData()
55 …: textRect_(textRect), frameWidth_(frameWidth), frameHeight_(frameHeight), lineHeight_(lineHeight), in TextDragData()
/ohos5.0/foundation/arkui/ace_engine/adapter/ohos/osal/
H A Dstylus_detector_callback.cpp329 auto textRect = textDragBase->GetTextRect(); in GetGlyphPositionByGlobalOffset() local
330 …if (localOffset.GetY() < textRect.GetY() || localOffset.GetY() > textRect.GetY() + textRect.Height… in GetGlyphPositionByGlobalOffset()
/ohos5.0/foundation/arkui/ace_engine/test/unittest/core/pattern/text/
H A Dtext_testtwo_ng.cpp1973 RectF textRect; variable
1974 textRect.SetHeight(TEXT_RECT_WIDTH);
1975 textRect.SetWidth(TEXT_RECT_WIDTH);
1976 textRect.SetTop(TEXT_RECT_TOP_ONE);
1977 drawObscuredRects.push_back(textRect);
1990 drawObscuredRects.push_back(textRect);
1991 textRect.SetTop(TEXT_RECT_TOP_TWO);
1992 drawObscuredRects.push_back(textRect);
2006 drawObscuredRects.push_back(textRect);
2019 textRect.SetWidth(TEXT_RECT_SIZE_ZEOR);
[all …]
H A Dtext_testfour_ng.cpp538 RectF textRect; variable
539 textRect.SetHeight(TEXT_RECT_WIDTH);
540 textRect.SetWidth(TEXT_RECT_WIDTH);
541 textRect.SetTop(TEXT_RECT_TOP_ONE);
542 drawObscuredRects.push_back(textRect);
555 drawObscuredRects.push_back(textRect);
556 textRect.SetTop(TEXT_RECT_TOP_TWO);
557 drawObscuredRects.push_back(textRect);
571 drawObscuredRects.push_back(textRect);
584 textRect.SetWidth(TEXT_RECT_SIZE_ZEOR);
[all …]
/ohos5.0/foundation/arkui/ace_engine/test/unittest/core/pattern/rich_editor/
H A Drich_editor_base_testone_ng.cpp816 auto textRect = richEditorPattern->GetTextRect(); variable
817 textRect.SetTop(textRect.GetY() - 0.0f);
818 textRect.SetHeight(textRect.Height() - 0.0f);
819 Offset offset = Offset(textRect.GetX(), textRect.GetY());
/ohos5.0/docs/zh-cn/release-notes/changelogs/OpenHarmony_4.0.9.2/
H A Dchangelogs-arkui.md131 1、Search/TextInput/TextArea中textRect中位置变更前仅相对padding偏移,变更后位置相对padding和border计算偏移。
/ohos5.0/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/text/
H A Dbase_text_select_overlay.cpp333 …const std::vector<RectF>& boxes, const RectF& contentRect, const RectF& textRect, const OffsetF& p… in MergeSelectedBoxes() argument
339 …res.SetRect(contentRect.GetX() + paintOffset.GetX(), frontRect.GetY() + textRect.GetY() + paintOff… in MergeSelectedBoxes()
342 res.SetRect(frontRect.GetX() + textRect.GetX() + paintOffset.GetX(), in MergeSelectedBoxes()
343 … frontRect.GetY() + textRect.GetY() + paintOffset.GetY(), backRect.Right() - frontRect.Left(), in MergeSelectedBoxes()
/ohos5.0/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/rich_editor/
H A Drich_editor_pattern.cpp2981 auto textRect = GetTextRect(); in HandleOnlyImageSelected() local
2982 textRect.SetTop(textRect.GetY() - std::min(baselineOffset_, 0.0f)); in HandleOnlyImageSelected()
2983 textRect.SetHeight(textRect.Height() - std::max(baselineOffset_, 0.0f)); in HandleOnlyImageSelected()
2984 Offset offset = Offset(textRect.GetX(), textRect.GetY()); in HandleOnlyImageSelected()
3086 auto textRect = GetTextRect(); in CalcCaretInfoByClick() local
3087 textRect.SetTop(textRect.GetY() - std::min(baselineOffset_, 0.0f)); in CalcCaretInfoByClick()
3088 textRect.SetHeight(textRect.Height() - std::max(baselineOffset_, 0.0f)); in CalcCaretInfoByClick()
3911 auto textRect = GetTextRect(); in OnDragMove() local
3912 textRect.SetTop(textRect.GetY() - std::min(baselineOffset_, 0.0f)); in OnDragMove()
6953 textRect.SetTop(textRect.GetY() - std::min(baselineOffset_, 0.0f)); in OnBackPressed()
[all …]

12