#include "third_party/blink/renderer/core/editing/ime/ime_text_span.h"
#include <algorithm>
#include "base/numerics/safe_conversions.h"
#include "ui/base/ime/ime_text_span.h"
#include "ui/base/ime/mojom/ime_types.mojom-blink.h"
namespace blink {
ImeTextSpan::Type ConvertUiTypeToType(ui::ImeTextSpan::Type type) { … }
ImeTextSpan::ImeTextSpan(Type type,
wtf_size_t start_offset,
wtf_size_t end_offset,
const Color& underline_color,
ui::mojom::ImeTextSpanThickness thickness,
ui::mojom::ImeTextSpanUnderlineStyle underline_style,
const Color& text_color,
const Color& background_color,
const Color& suggestion_highlight_color,
bool remove_on_finish_composing,
bool interim_char_selection,
const Vector<String>& suggestions)
: … { … }
namespace {
Vector<String> ConvertStdVectorOfStdStringsToVectorOfStrings(
const std::vector<std::string>& input) { … }
std::vector<std::string> ConvertVectorOfStringsToStdVectorOfStdStrings(
const Vector<String>& input) { … }
ui::mojom::ImeTextSpanThickness ConvertUiThicknessToThickness(
ui::ImeTextSpan::Thickness thickness) { … }
ui::mojom::ImeTextSpanUnderlineStyle ConvertUiUnderlineToUnderline(
ui::ImeTextSpan::UnderlineStyle underline) { … }
ui::ImeTextSpan::Type ConvertImeTextSpanTypeToUiType(ImeTextSpan::Type type) { … }
}
ImeTextSpan::ImeTextSpan(const ui::ImeTextSpan& ime_text_span)
: … { … }
ui::ImeTextSpan ImeTextSpan::ToUiImeTextSpan() { … }
}