From 4d49156dac68a626141806cc8dc5b2951ff73198 Mon Sep 17 00:00:00 2001 From: Samuel Attard Date: Sat, 8 Oct 2016 13:09:31 +1100 Subject: [PATCH] Rename bounds -> rectangle --- docs/api/browser-window.md | 16 ++++++++-------- docs/api/screen.md | 2 +- docs/api/structures/bounds.md | 6 ------ docs/api/structures/certificate.md | 2 +- docs/api/structures/display.md | 6 +++--- docs/api/structures/jump-list-category.md | 2 +- docs/api/structures/jump-list-item.md | 2 +- docs/api/structures/memory-usage-details.md | 2 +- docs/api/structures/rectangle.md | 6 ++++++ docs/api/structures/shortcut-details.md | 2 +- docs/api/structures/task.md | 2 +- docs/api/structures/thumbar-button.md | 2 +- docs/api/tray.md | 8 ++++---- docs/api/web-contents.md | 4 ++-- 14 files changed, 31 insertions(+), 31 deletions(-) delete mode 100644 docs/api/structures/bounds.md create mode 100644 docs/api/structures/rectangle.md diff --git a/docs/api/browser-window.md b/docs/api/browser-window.md index 7b459c24648..b42f397a49d 100644 --- a/docs/api/browser-window.md +++ b/docs/api/browser-window.md @@ -664,20 +664,20 @@ the player itself we would call this function with arguments of 16/9 and are within the content view--only that they exist. Just sum any extra width and height areas you have within the overall content view. -#### `win.setBounds(options[, animate])` +#### `win.setBounds(bounds[, animate])` -* `options` [Bounds](structures/bounds.md) +* `bounds` [Rectangle](structures/rectangle.md) * `animate` Boolean (optional) _macOS_ Resizes and moves the window to the supplied bounds #### `win.getBounds()` -Returns [`Bounds`](structures/bounds.md) +Returns [`Rectangle`](structures/rectangle.md) -#### `win.setContentBounds(options[, animate])` +#### `win.setContentBounds(bounds[, animate])` -* `options` [Bounds](structures/bounds.md) +* `bounds` [Rectangle](structures/rectangle.md) * `animate` Boolean (optional) _macOS_ Resizes and moves the window's client area (e.g. the web page) to @@ -685,7 +685,7 @@ the supplied bounds. #### `win.getContentBounds()` -Returns [`Bounds`](structures/bounds.md) +Returns [`Rectangle`](structures/rectangle.md) #### `win.setSize(width, height[, animate])` @@ -948,7 +948,7 @@ Whether `Boolean` - Whether the window's document has been edited. #### `win.capturePage([rect, ]callback)` -* `rect` [Bounds](structures/bounds.md) (optional) - The bounds to capture +* `rect` [Rectangle](structures/rectangle.md) (optional) - The bounds to capture * `callback` Function Same as `webContents.capturePage([rect, ]callback)`. @@ -1075,7 +1075,7 @@ The `flags` is an array that can include following `String`s: #### `win.setThumbnailClip(region)` _Windows_ -* `region` [Bounds](structures/bounds.md) - Region of the window +* `region` [Rectangle](structures/rectangle.md) - Region of the window Sets the region of the window to show as the thumbnail image displayed when hovering over the window in the taskbar. You can reset the thumbnail to be diff --git a/docs/api/screen.md b/docs/api/screen.md index fbbbef929dc..ebc2be45ab7 100644 --- a/docs/api/screen.md +++ b/docs/api/screen.md @@ -113,6 +113,6 @@ Returns `Display` - The display nearest the specified point. ### `screen.getDisplayMatching(rect)` -* `rect` [Bounds](structures/bounds.md) +* `rect` [Rectangle](structures/rectangle.md) Returns `Display` - The display that most closely intersects the provided bounds. diff --git a/docs/api/structures/bounds.md b/docs/api/structures/bounds.md deleted file mode 100644 index 9a7406a51ec..00000000000 --- a/docs/api/structures/bounds.md +++ /dev/null @@ -1,6 +0,0 @@ -# Bounds - -* `x` Number -* `y` Number -* `width` Number -* `height` Number diff --git a/docs/api/structures/certificate.md b/docs/api/structures/certificate.md index 19a2027d403..95e15ceadaf 100644 --- a/docs/api/structures/certificate.md +++ b/docs/api/structures/certificate.md @@ -1,4 +1,4 @@ -# Certificate +# Certificate Object * `data` String - PEM encoded data * `issuerName` String - Issuer's Common Name diff --git a/docs/api/structures/display.md b/docs/api/structures/display.md index d3949277e18..d702b35a1be 100644 --- a/docs/api/structures/display.md +++ b/docs/api/structures/display.md @@ -1,15 +1,15 @@ -# Display +# Display Object * `id` Number - Unique identifier associated with the display. * `rotation` Number - Can be 0, 90, 180, 270, represents screen rotation in clock-wise degrees. * `scaleFactor` Number - Output device's pixel scale factor. * `touchSupport` String - Can be `available`, `unavailable`, `unknown`. -* `bounds` [Bounds](bounds.md) +* `bounds` [Rectangle](rectangle.md) * `size` Object * `height` Number * `width` Number -* `workArea` [Bounds](bounds.md) +* `workArea` [Rectangle](rectangle.md) * `workAreaSize` Object * `height` Number * `width` Number diff --git a/docs/api/structures/jump-list-category.md b/docs/api/structures/jump-list-category.md index dbec04c2f6d..71bf0e49b5f 100644 --- a/docs/api/structures/jump-list-category.md +++ b/docs/api/structures/jump-list-category.md @@ -1,4 +1,4 @@ -# JumpListCategory +# JumpListCategory Object * `type` String - One of the following: * `tasks` - Items in this category will be placed into the standard `Tasks` diff --git a/docs/api/structures/jump-list-item.md b/docs/api/structures/jump-list-item.md index c34b4097c4b..a58293a4ca9 100644 --- a/docs/api/structures/jump-list-item.md +++ b/docs/api/structures/jump-list-item.md @@ -1,4 +1,4 @@ -# JumpListItem +# JumpListItem Object * `type` String - One of the following: * `task` - A task will launch an app with specific arguments. diff --git a/docs/api/structures/memory-usage-details.md b/docs/api/structures/memory-usage-details.md index 91d1e154107..228a4452907 100644 --- a/docs/api/structures/memory-usage-details.md +++ b/docs/api/structures/memory-usage-details.md @@ -1,4 +1,4 @@ -# MemoryUsageDetails +# MemoryUsageDetails Object * `count` Number * `size` Number diff --git a/docs/api/structures/rectangle.md b/docs/api/structures/rectangle.md new file mode 100644 index 00000000000..0cd000699ea --- /dev/null +++ b/docs/api/structures/rectangle.md @@ -0,0 +1,6 @@ +# Rectangle Object + +* `x` Number - The x coordinate of the origin of the rectangle +* `y` Number - The y coordinate of the origin of the rectangle +* `width` Number +* `height` Number diff --git a/docs/api/structures/shortcut-details.md b/docs/api/structures/shortcut-details.md index c57c345ba6e..e7b272d0999 100644 --- a/docs/api/structures/shortcut-details.md +++ b/docs/api/structures/shortcut-details.md @@ -1,4 +1,4 @@ -# ShortcutDetails +# ShortcutDetails Object * `target` String - The target to launch from this shortcut. * `cwd` String (optional) - The working directory. Default is empty. diff --git a/docs/api/structures/task.md b/docs/api/structures/task.md index a73ff099084..61a28de879e 100644 --- a/docs/api/structures/task.md +++ b/docs/api/structures/task.md @@ -1,4 +1,4 @@ -# Task +# Task Object * `program` String - Path of the program to execute, usually you should specify `process.execPath` which opens the current program. diff --git a/docs/api/structures/thumbar-button.md b/docs/api/structures/thumbar-button.md index c029e881bb4..324ee062d7d 100644 --- a/docs/api/structures/thumbar-button.md +++ b/docs/api/structures/thumbar-button.md @@ -1,4 +1,4 @@ -# ThumbarButton +# ThumbarButton Object * `icon` [NativeImage](native-image.md) - The icon showing in thumbnail toolbar. diff --git a/docs/api/tray.md b/docs/api/tray.md index 2d567b83646..ed9747ec354 100644 --- a/docs/api/tray.md +++ b/docs/api/tray.md @@ -70,7 +70,7 @@ The `Tray` module emits the following events: * `shiftKey` Boolean * `ctrlKey` Boolean * `metaKey` Boolean -* `bounds` [Bounds](structures/bounds.md) - The bounds of tray icon +* `bounds` [Rectangle](structures/rectangle.md) - The bounds of tray icon Emitted when the tray icon is clicked. @@ -81,7 +81,7 @@ Emitted when the tray icon is clicked. * `shiftKey` Boolean * `ctrlKey` Boolean * `metaKey` Boolean -* `bounds` [Bounds](structures/bounds.md) - The bounds of tray icon +* `bounds` [Rectangle](structures/rectangle.md) - The bounds of tray icon Emitted when the tray icon is right clicked. @@ -92,7 +92,7 @@ Emitted when the tray icon is right clicked. * `shiftKey` Boolean * `ctrlKey` Boolean * `metaKey` Boolean -* `bounds` [Bounds](structures/bounds.md) - The bounds of tray icon +* `bounds` [Rectangle](structures/rectangle.md) - The bounds of tray icon Emitted when the tray icon is double clicked. @@ -231,7 +231,7 @@ Sets the context menu for this icon. #### `tray.getBounds()` _macOS_ _Windows_ -Returns [`Bounds`](structures/bounds.md) +Returns [`Rectangle`](structures/rectangle.md) The `bounds` of this tray icon as `Object`. diff --git a/docs/api/web-contents.md b/docs/api/web-contents.md index 0a831d71de6..106934ab0b6 100644 --- a/docs/api/web-contents.md +++ b/docs/api/web-contents.md @@ -465,7 +465,7 @@ app.on('ready', () => { Returns: * `event` Event -* `dirtyRect` [Bounds](structures/bounds.md) +* `dirtyRect` [Rectangle](structures/rectangle.md) * `image` [NativeImage](native-image.md) - The image data of the whole frame. Emitted when a new frame is generated. Only the dirty area is passed in the @@ -780,7 +780,7 @@ console.log(requestId) #### `contents.capturePage([rect, ]callback)` -* `rect` [Bounds](structures/bounds.md) (optional) - The area of the page to be captured +* `rect` [Rectangle](structures/rectangle.md) (optional) - The area of the page to be captured * `callback` Function Captures a snapshot of the page within `rect`. Upon completion `callback` will