Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -142,7 +142,7 @@ def plot_triangle(vertices, properties):
|
|
| 142 |
])
|
| 143 |
handles.extend([
|
| 144 |
plt.Line2D([0], [0], linestyle='-', color='blue', markersize=6, label=f"Side {side}: {length:.1f}")
|
| 145 |
-
for side, length in zip(['a = BC', 'b
|
| 146 |
])
|
| 147 |
handles.extend([
|
| 148 |
plt.Line2D([0], [0], marker='o', markerfacecolor='white', markeredgecolor='red', markersize=5, linestyle='none', label=f"Incircle radius: {radius_in:.1f}"),
|
|
@@ -227,10 +227,10 @@ def main():
|
|
| 227 |
for point, label in [('1', 'A'), ('2', 'B'), ('3', 'C')]:
|
| 228 |
cols = st.sidebar.columns([3, 3])
|
| 229 |
coordinates[f'x{point}'] = cols[0].number_input(
|
| 230 |
-
f"X{point}", min_value=-100.0, max_value=100.0, step=0.1, format="%.3f"
|
| 231 |
)
|
| 232 |
coordinates[f'y{point}'] = cols[1].number_input(
|
| 233 |
-
f"Y{point}", min_value=-100.0, max_value=100.0, step=0.1, format="%.3f"
|
| 234 |
)
|
| 235 |
return coordinates
|
| 236 |
|
|
|
|
| 142 |
])
|
| 143 |
handles.extend([
|
| 144 |
plt.Line2D([0], [0], linestyle='-', color='blue', markersize=6, label=f"Side {side}: {length:.1f}")
|
| 145 |
+
for side, length in zip(['a = BC', 'b = AC', 'c = AB'], [a, b, c])
|
| 146 |
])
|
| 147 |
handles.extend([
|
| 148 |
plt.Line2D([0], [0], marker='o', markerfacecolor='white', markeredgecolor='red', markersize=5, linestyle='none', label=f"Incircle radius: {radius_in:.1f}"),
|
|
|
|
| 227 |
for point, label in [('1', 'A'), ('2', 'B'), ('3', 'C')]:
|
| 228 |
cols = st.sidebar.columns([3, 3])
|
| 229 |
coordinates[f'x{point}'] = cols[0].number_input(
|
| 230 |
+
f"X{point}", value=0.0, min_value=-100.0, max_value=100.0, step=0.1, format="%.3f"
|
| 231 |
)
|
| 232 |
coordinates[f'y{point}'] = cols[1].number_input(
|
| 233 |
+
f"Y{point}", value=0.0, min_value=-100.0, max_value=100.0, step=0.1, format="%.3f"
|
| 234 |
)
|
| 235 |
return coordinates
|
| 236 |
|