Spaces:
Runtime error
Runtime error
Update app.py
Browse files482 unmodified lines4834844854864874884892 unmodified lines49249349449549649749825 unmodified lines524525526527528529530531532533534535536482 unmodified linesst.header("🖌️ Interactive Text Addition")# Display the canvas with drawable featurescanvas_result = st_canvas(fill_color="rgba(255, 255, 255, 0)", # Transparent fillstroke_width=0,2 unmodified linesupdate_streamlit=True,height=canvas_image.height,width=canvas_image.width,drawing_mode="freedraw",key="canvas",# Hide the drawing toolbardisplay_toolbar=False,25 unmodified lines'blending_mode': "Normal"}add_layer(layer)st.success("Interactive text added!")# Reset click position and text inputst.session_state['click_position'] = Nonest.session_state['text_input'] = ""else:st.warning("Please enter some text.")# ------------------------------# Process Layers and Render Image# ------------------------------482 unmodified lines4834844854864874884892 unmodified lines49249349449549649749825 unmodified lines524525526527528529530531532533534535536482 unmodified linesst.header("🖌️ Interactive Text Addition")# Define canvas parameterscanvas_result = st_canvas(fill_color="rgba(255, 255, 255, 0)", # Transparent fillstroke_width=0,2 unmodified linesupdate_streamlit=True,height=canvas_image.height,width=canvas_image.width,drawing_mode="point",key="canvas",# Hide the drawing toolbardisplay_toolbar=False,25 unmodified lines'blending_mode': "Normal"}add_layer(layer)st.sidebar.success("Interactive text added!")# Reset click position and text inputst.session_state['click_position'] = Nonest.session_state['text_input'] = ""else:st.warning("Please enter some text.")# ------------------------------# Process Layers and Render Image# ------------------------------
app.py+4-4