SVG.ipynb
47 lines
| 977 B
| text/plain
|
TextLexer
|
r17082 | { | |
|
r18580 | "cells": [ | |
|
r17082 | { | |
|
r18580 | "cell_type": "code", | |
|
r18587 | "execution_count": 1, | |
|
r18580 | "metadata": { | |
"collapsed": false | |||
}, | |||
"outputs": [], | |||
"source": [ | |||
"from IPython.display import SVG" | |||
] | |||
}, | |||
{ | |||
"cell_type": "code", | |||
|
r18587 | "execution_count": 2, | |
|
r18580 | "metadata": { | |
"collapsed": false | |||
}, | |||
"outputs": [ | |||
|
r17082 | { | |
|
r18589 | "data": { | |
"image/svg+xml": [ | |||
"<svg height=\"100\" width=\"100\">\n", | |||
" <circle cx=\"50\" cy=\"50\" fill=\"red\" r=\"40\" stroke=\"black\" stroke-width=\"2\"/>\n", | |||
"</svg>" | |||
], | |||
"text/plain": [ | |||
"<IPython.core.display.SVG object>" | |||
] | |||
}, | |||
|
r18587 | "execution_count": 2, | |
|
r17082 | "metadata": {}, | |
|
r18589 | "output_type": "execute_result" | |
|
r17082 | } | |
], | |||
|
r18580 | "source": [ | |
"SVG(data='''\n", | |||
"<svg height=\"100\" width=\"100\">\n", | |||
" <circle cx=\"50\" cy=\"50\" r=\"40\" stroke=\"black\" stroke-width=\"2\" fill=\"red\" />\n", | |||
"</svg>''')" | |||
] | |||
|
r17082 | } | |
|
r18580 | ], | |
"metadata": {}, | |||
"nbformat": 4, | |||
"nbformat_minor": 0 | |||
|
r17082 | } |