Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(613)

Unified Diff: services/ui/public/interfaces/ime/ime.mojom

Issue 2839243002: IME for Mus: Structs and StructTraits for IME Candidate Window. (Closed)
Patch Set: Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: services/ui/public/interfaces/ime/ime.mojom
diff --git a/services/ui/public/interfaces/ime/ime.mojom b/services/ui/public/interfaces/ime/ime.mojom
index c122750e99d4a18f748348fad9808c25e801c7ab..2df8bf1b37ef356012337d928a66fba2f3555add 100644
--- a/services/ui/public/interfaces/ime/ime.mojom
+++ b/services/ui/public/interfaces/ime/ime.mojom
@@ -9,6 +9,53 @@ import "ui/events/mojo/event.mojom";
import "ui/gfx/geometry/mojo/geometry.mojom";
import "ui/gfx/range/mojo/range.mojom";
+// Specifies where to display the candidate window.
+enum CandidateWindowPosition {
+ // Candidate window follows the cursor.
+ CURSOR,
sky 2017/04/26 20:03:23 The *new* style for enums is kFoo.
Hadi 2017/04/27 12:34:20 Done.
+
+ // Candidate window is locked to the beginning of the composition.
+ COMPOSITION
+};
+
+struct CandidateWindowProperties {
+ // Number of candidates to display per page.
+ int32 page_size;
+
+ // Should candidate window be rendered vertical or horizontal.
+ bool vertical;
+
+ // Text that is shown at the bottom of the candidate window.
+ string auxiliary_text;
+
+ // True to display auxiliary text, false to hide it.
+ bool auxiliary_text_visible;
+
+ // Position and visibility of cursor in the candidate window.
+ int32 cursor_position;
+ bool cursor_visible;
+
+ // Where to display the candidate window.
+ CandidateWindowPosition window_position;
+};
+
+// Represents a candidate window entry.
+struct CandidateWindowEntry {
+ // Value of the candidate.
+ string value;
+
+ // Short string displayed next to the candidate, often the shortcut key or
+ // index.
+ string label;
+
+ // Additional text describing the candidate.
+ string annotation;
+
+ // The usage or detailed description of the candidate.
+ string description_title;
+ string description_body;
+};
+
// Represents an underlined segment of text currently composed by IME.
// Corresponds to ui::CompositionUnderline.
struct CompositionUnderline {

Powered by Google App Engine
This is Rietveld 408576698