import streamlit as st # Set up the page configuration st.set_page_config(page_title="AutoCAD Command Explorer", layout="wide") # Commands categorized by functionality (add as many as necessary) commands = { "DRAWING": { "3DORBIT": { "description": "Rotates the view in 3D space around a pivot point.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-3DORBIT" }, "LINE": { "description": "Creates straight line segments between two points.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-LINE" }, "CIRCLE": { "description": "Creates a circle based on a center point and radius.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-CIRCLE" }, "ARC": { "description": "Creates an arc defined by three points.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-ARC" }, "SPLINE": { "description": "Creates a spline curve through a set of points.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-SPLINE" } }, "MODIFYING": { "MOVE": { "description": "Moves objects a specified distance in a specified direction.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-MOVE" }, "COPY": { "description": "Copies objects a specified distance in a specified direction.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-COPY" }, "ROTATE": { "description": "Rotates objects around a base point.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-ROTATE" }, "SCALE": { "description": "Scales objects proportionally from a specified base point.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-SCALE" }, "EXPLODE": { "description": "Breaks a compound object into its constituent objects.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-EXPLODE" } }, "DIMENSIONS": { "DIMLINEAR": { "description": "Creates a linear dimension between two points.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-DIMLINEAR" }, "DIMRADIUS": { "description": "Creates a dimension that measures the radius of a circle or arc.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-DIMRADIUS" }, "DIMDIAMETER": { "description": "Creates a dimension that measures the diameter of a circle or arc.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-DIMDIAMETER" } }, "VIEWING": { "ZOOM": { "description": "Changes the view of your drawing to a specific zoom level.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-ZOOM" }, "PAN": { "description": "Pans the view of your drawing.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-PAN" }, "3DVIEW": { "description": "Sets the 3D view angle and position.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-3DVIEW" } }, "LAYER_MANAGEMENT": { "LAYER": { "description": "Manages drawing layers and their properties.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-LAYER" }, "LAYERSTATE": { "description": "Saves and restores layer settings.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-LAYERSTATE" } }, "OTHER": { "UNDO": { "description": "Reverses the last action or command.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-UNDO" }, "REDO": { "description": "Reapplies the most recent undone action.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-REDO" }, "SAVE": { "description": "Saves the current drawing to a file.", "link": "https://help.autodesk.com/view/ACD/2025/ENU/?guid=GUID-SAVE" } } } # Custom CSS for styling st.markdown(""" """, unsafe_allow_html=True) # Title st.markdown('
📘 AutoCAD Command Explorer
', unsafe_allow_html=True) # Filter categories categories = list(commands.keys()) # Category filter dropdown category = st.selectbox("Select a Category:", categories) # Get the list of commands from the selected category category_commands = commands[category] # Command dropdown in selected category selected_cmd = st.selectbox("Select a Command:", sorted(category_commands.keys())) # Layout: Description on the right col1, col2 = st.columns([1, 2]) with col1: # Show description and link of the selected command cmd = category_commands[selected_cmd] st.markdown(f"""
🛠️ {selected_cmd}
{cmd['description']}
""", unsafe_allow_html=True)