Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -21,13 +21,7 @@ print([(k, type(v)) for (k, v) in state.items()])
|
|
21 |
# st.write(x, 'squared is', x * x)
|
22 |
|
23 |
# Specify canvas parameters in application
|
24 |
-
drawing_mode = st.sidebar.selectbox(
|
25 |
-
"Drawing tool:",
|
26 |
-
("freedraw", "line", "rect", "circle", "transform", "polygon", "point"),
|
27 |
-
)
|
28 |
stroke_width = st.sidebar.slider("Stroke width: ", 1, 25, 3)
|
29 |
-
if drawing_mode == "point":
|
30 |
-
point_display_radius = st.sidebar.slider("Point display radius: ", 1, 25, 3)
|
31 |
realtime_update = st.sidebar.checkbox("Update in realtime", True)
|
32 |
|
33 |
# Create a canvas component
|
@@ -38,9 +32,10 @@ canvas_result = st_canvas(
|
|
38 |
background_color="rgb(0, 0, 0)",
|
39 |
background_image=None,
|
40 |
update_streamlit=realtime_update,
|
41 |
-
height=
|
42 |
-
|
43 |
-
|
|
|
44 |
display_toolbar=st.sidebar.checkbox("Display toolbar", True),
|
45 |
key="full_app",
|
46 |
)
|
|
|
21 |
# st.write(x, 'squared is', x * x)
|
22 |
|
23 |
# Specify canvas parameters in application
|
|
|
|
|
|
|
|
|
24 |
stroke_width = st.sidebar.slider("Stroke width: ", 1, 25, 3)
|
|
|
|
|
25 |
realtime_update = st.sidebar.checkbox("Update in realtime", True)
|
26 |
|
27 |
# Create a canvas component
|
|
|
32 |
background_color="rgb(0, 0, 0)",
|
33 |
background_image=None,
|
34 |
update_streamlit=realtime_update,
|
35 |
+
height=28,
|
36 |
+
width=28,
|
37 |
+
drawing_mode="freedraw",
|
38 |
+
point_display_radius=0,
|
39 |
display_toolbar=st.sidebar.checkbox("Display toolbar", True),
|
40 |
key="full_app",
|
41 |
)
|