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

Side by Side Diff: chrome/common/extensions/api/experimental.fontSettings.json

Issue 10107014: Migrate WebKit "global script" font prefs. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: compile fixes Created 8 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 [ 5 [
6 { 6 {
7 "namespace": "experimental.fontSettings", 7 "namespace": "experimental.fontSettings",
8 "types": [ 8 "types": [
9 { 9 {
10 "id": "FontName", 10 "id": "FontName",
11 "type": "object", 11 "type": "object",
12 "description": "Represents a font name.", 12 "description": "Represents a font name.",
13 "properties": { 13 "properties": {
14 "fontName": { 14 "fontName": {
15 "type": "string", 15 "type": "string",
16 "description": "The font name." 16 "description": "The font name."
17 }, 17 },
18 "localizedName": { 18 "localizedName": {
19 "type": "string", 19 "type": "string",
20 "description": "The font name localized for the current locale." 20 "description": "The font name localized for the current locale."
21 } 21 }
22 } 22 }
23 }, 23 },
24 { 24 {
25 "id": "ScriptCode", 25 "id": "ScriptCode",
26 "type": "string", 26 "type": "string",
27 "enum": [ "Arab", "Armn", "Beng", "Cans", "Cher", "Cyrl", "Deva", "Ethi" , "Geor", 27 "enum": [ "Arab", "Armn", "Beng", "Cans", "Cher", "Cyrl", "Deva", "Ethi" , "Geor",
28 "Grek", "Gujr", "Guru", "Hang", "Hans", "Hant", "Hebr", "Hrkt" , "Knda", 28 "Grek", "Gujr", "Guru", "Hang", "Hans", "Hant", "Hebr", "Hrkt" , "Knda",
29 "Khmr", "Laoo", "Mlym", "Mong", "Mymr", "Orya", "Sinh", "Taml" , "Telu", 29 "Khmr", "Laoo", "Mlym", "Mong", "Mymr", "Orya", "Sinh", "Taml" , "Telu",
30 "Thaa", "Thai", "Tibt", "Yiii" 30 "Thaa", "Thai", "Tibt", "Yiii", "Zyyy"
31 ], 31 ],
32 "description": "An ISO 15924 script code." 32 "description": "An ISO 15924 script code. The default, or global, script is represented by script code \"Zyyy\"."
33 }, 33 },
34 { 34 {
35 "id": "GenericFamily", 35 "id": "GenericFamily",
36 "type": "string", 36 "type": "string",
37 "enum": ["standard", "sansserif", "serif", "fixed", "cursive", "fantasy" ], 37 "enum": ["standard", "sansserif", "serif", "fixed", "cursive", "fantasy" ],
38 "description": "A CSS generic font family." 38 "description": "A CSS generic font family."
39 } 39 }
40 ], 40 ],
41 "functions": [ 41 "functions": [
42 { 42 {
43 "name": "getFont", 43 "name": "getFont",
44 "description": "Gets the current font setting for a given script and gen eric font family.", 44 "description": "Gets the current font setting for a given script and gen eric font family.",
45 "parameters": [ 45 "parameters": [
46 { 46 {
47 "name": "details", 47 "name": "details",
48 "type": "object", 48 "type": "object",
49 "properties": { 49 "properties": {
50 "script": { 50 "script": {
51 "$ref": "ScriptCode", 51 "$ref": "ScriptCode",
52 "description": "The script for which the font setting should be retrieved. If omitted, the global script font setting is retrieved.", 52 "description": "The script for which the font setting should be retrieved. If omitted, the font setting for the global script (script code \"Zyy y\") is retrieved.",
53 "optional": true 53 "optional": true
54 }, 54 },
55 "genericFamily": { 55 "genericFamily": {
56 "$ref": "GenericFamily", 56 "$ref": "GenericFamily",
57 "description": "The generic font family for which the font setti ng should be retrieved." 57 "description": "The generic font family for which the font setti ng should be retrieved."
58 } 58 }
59 } 59 }
60 }, 60 },
61 { 61 {
62 "type": "function", 62 "type": "function",
(...skipping 17 matching lines...) Expand all
80 { 80 {
81 "name": "setFont", 81 "name": "setFont",
82 "description": "Sets the font setting for a given script and generic fon t family.", 82 "description": "Sets the font setting for a given script and generic fon t family.",
83 "parameters": [ 83 "parameters": [
84 { 84 {
85 "name": "details", 85 "name": "details",
86 "type": "object", 86 "type": "object",
87 "properties": { 87 "properties": {
88 "script": { 88 "script": {
89 "$ref": "ScriptCode", 89 "$ref": "ScriptCode",
90 "description": "The script code which the font setting should be set. If omitted, the global script font setting is set.", 90 "description": "The script code which the font setting should be set. If omitted, the font setting for the global script (script code \"Zyyy\") is set.",
91 "optional": true 91 "optional": true
92 }, 92 },
93 "genericFamily": { 93 "genericFamily": {
94 "$ref": "GenericFamily", 94 "$ref": "GenericFamily",
95 "description": "The generic font family for which the font setti ng should be set." 95 "description": "The generic font family for which the font setti ng should be set."
96 }, 96 },
97 "fontName": { 97 "fontName": {
98 "type": "string", 98 "type": "string",
99 "description": "The font name. If a script is specified, the emp ty string means to fallback to the global script font setting." 99 "description": "The font name. If a script is specified, the emp ty string means to fallback to the global script font setting."
100 } 100 }
(...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after
284 "name": "onFontChanged", 284 "name": "onFontChanged",
285 "description": "Fired when a font setting changes.", 285 "description": "Fired when a font setting changes.",
286 "parameters": [ 286 "parameters": [
287 { 287 {
288 "type": "object", 288 "type": "object",
289 "name": "details", 289 "name": "details",
290 "properties": { 290 "properties": {
291 "fontName": { "type": "string" }, 291 "fontName": { "type": "string" },
292 "script": { 292 "script": {
293 "$ref": "ScriptCode", 293 "$ref": "ScriptCode",
294 "description": "The script code for which the font setting has c hanged. If omitted, the global script font setting has changed.", 294 "description": "The script code for which the font setting has c hanged.",
295 "optional": true 295 "optional": true
296 }, 296 },
297 "genericFamily": { 297 "genericFamily": {
298 "$ref": "GenericFamily", 298 "$ref": "GenericFamily",
299 "description": "The generic font family for which the font setti ng has changed." 299 "description": "The generic font family for which the font setti ng has changed."
300 }, 300 },
301 "levelOfControl": { 301 "levelOfControl": {
302 "description": "One of<br><var>not_controllable</var>: cannot be controlled by any extension<br><var>controlled_by_other_extensions</var>: contr olled by extensions with higher precedence<br><var>controllable_by_this_extensio n</var>: can be controlled by this extension<br><var>controlled_by_this_extensio n</var>: controlled by this extension", 302 "description": "One of<br><var>not_controllable</var>: cannot be controlled by any extension<br><var>controlled_by_other_extensions</var>: contr olled by extensions with higher precedence<br><var>controllable_by_this_extensio n</var>: can be controlled by this extension<br><var>controlled_by_this_extensio n</var>: controlled by this extension",
303 "type": "string", 303 "type": "string",
304 "enum": ["not_controllable", "controlled_by_other_extensions", " controllable_by_this_extension", "controlled_by_this_extension"] 304 "enum": ["not_controllable", "controlled_by_other_extensions", " controllable_by_this_extension", "controlled_by_this_extension"]
305 } 305 }
306 } 306 }
307 } 307 }
308 ] 308 ]
309 } 309 }
310 ] 310 ]
311 } 311 }
312 ] 312 ]
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698