this plugin is no longer maintained since image resize is now built into Google Docs.

SetImageSize is a Google Docs Addon that allows you to precisely set the size of an image. You can install it from this page. I had fun creating it and am curious if it will be used…

note: when I first created this Addon Google docs was not able to resize images. This feature has recently been added so maybe you want to try that first.

ImageSizeIcon

how to use (here is a video)

  • activate the add-on. You do this by selecting “Add-ons” on the top menu. Then select “SetImageSize”, then select “show sidebar”. You should now see the sidebar on the right.
  • select an image in your document by clicking on the image. The image should be in bmp, gif, jpg or png format. The text flow of the image has to be set to ‘in-line’.
  • retrieve the size of the selected image with the “Get size” button in the sidebar on the right.
  • change the width & height to your liking. You can set the size in pixels, inches & cm.
  • select “Apply” to set the new size.
  • use the padlock icon to lock and unlock aspect ratio.
  • the 1:1 button retrieves the size of the original image (as stored in the image).
  • you can edit your own preferred shortcuts.

limitation

The add on works with bitmap images (bmp, gif, jpg, png) set to ‘inline’ only (because of Google Docs API limitation). When you select an image in Docs you can indicate how the text flows around the image. The options are ‘In line’, ‘Wrap text’ and ‘Break text’; only ‘In line’ will work.

privacy policy

This add-on will only access the current document. It will not copy any document data anywhere outside of your document. Also no personal data is captured or stored.

terms of use

THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

coding experience

The programming took some getting used to. The scripts that manipulate the document object model actually run on the server and you need to use a call-back mechanism from the HTML in the browser (the sidebar) to the server-side script. Once that was clear the rest was pretty easy. I probably spent more time on the UI than on the server code. The reviewer gave quick and excellent feedback to make the add-on better. Pretty nice experience. Sometimes Google makes some breaking changes to the API (e.g. the security model), then it sometimes takes a bit of time for me to realise what is going on and find the time to fix it.