The plot line is not visible at the maximum and minimum y-values
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 38/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Domain
- data-visualization, desktop
Research direction
Run the provided Dear PyGui example with add_plot_axis and add_line_series, then compare it with the set_axis_limits workaround. Trace the plot axis-limit handling used by this example and verify behavior at the minimum and maximum y-values. Done means the line remains visible at both bounds without requiring manual axis limits.
Written by the indexing model from the issue text.
Description
Version of Dear PyGui
Version: 2.0.0
Python: 3.12.9
Operating System: Windows 11
Issue
The plot line is not visible at the maximum and minimum y-values
import dearpygui.dearpygui as dpg
dpg.create_context()
dpg.create_viewport(title="Simple DearPyGUI Plot", width=600, height=400)
x_data = [0, 1, 2, 3, 4, 5]
y_data = [0, 0, 0, 1, 1, 1]
with dpg.window(label="Plot Example", width=580, height=380):
with dpg.plot(label="Line Plot", height=-1, width=-1):
dpg.add_plot_axis(dpg.mvXAxis, label="X Axis")
y_axis = dpg.add_plot_axis(dpg.mvYAxis, label="Y Axis", tag='yax')
dpg.add_line_series(x_data, y_data, label="Line Series", parent=y_axis)
dpg.setup_dearpygui()
dpg.show_viewport()
dpg.start_dearpygui()
dpg.destroy_context()
Expected behavior
using workaround
if rng := max(y_data)-min(y_data) > 0:
dpg.set_axis_limits('yax', min(y_data)-0.1*rng, max(y_data)+0.1*rng)
- Dominant language
- C++
- Stars
- 15.7k
- Forks
- 790
- PR merge metrics
- No merged PRs in 30d
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from hoffstadt/DearPyGui
-
Plot series data silently truncated to float32 when passed as numpy array (should be float64/double)Openstate: pending type: bug
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
-
state: pending type: bug
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
-
state: pending type: improvement
Difficulty 3/5 1-2 days Newbie friendliness 35/100
-
state: pending type: bug
Difficulty 4/5 3-5 days Newbie friendliness 42/100
-
state: pending type: improvement
Difficulty 5/5 Over a week Newbie friendliness 25/100
All issues in hoffstadt/DearPyGui
Similar issues
-
[Windows] Hidden title bar: a maximized window restored from minimized on a secondary monitor gets the primary monitor's work area as its client areaPossibly taken @lijy91 claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 67/100
libnativeapi/nativeapi#53 · 1 reaction ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 90/100
Maintainers usually reply within 1 day
-
bot-triaged module: correctness (silent) module: fft triage review
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 68/100
patrickjquinn/Marathon-Shell#84 ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 80/100
Maintainers usually reply within 1 day