Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wrong y zoom with empty hbar histogram #12567

Closed
1 task done
ferdymercury opened this issue Mar 28, 2023 · 6 comments
Closed
1 task done

Wrong y zoom with empty hbar histogram #12567

ferdymercury opened this issue Mar 28, 2023 · 6 comments
Assignees
Labels

Comments

@ferdymercury
Copy link
Collaborator

  • Checked for duplicates

Describe the bug

Draw hbar is supposed to be the same as bar, but rotated. However, this fails if the histogram is empty.

Expected behavior

hbar shows the same as bar, but rotated 90 degrees

To Reproduce

auto c = new TCanvas()
c->Divide(2,1)
auto h = new TH1F()
c->cd(1)
h->Draw("bar")
c->cd(2)
h->Draw("hbar")

unnamed

Setup

   ------------------------------------------------------------------
  | Welcome to ROOT 6.26/06                        https://root.cern |
  | (c) 1995-2021, The ROOT Team; conception: R. Brun, F. Rademakers |
  | Built for linuxx8664gcc on Jul 28 2022, 18:08:51                 |
  | From tags/v6-26-06@v6-26-06                                      |
  | With c++ (Ubuntu 11.2.0-19ubuntu1) 11.2.0                        |
  | Try '.help', '.demo', '.license', '.credits', '.quit'/'.q'       |
   ------------------------------------------------------------------

Additional context

#12566

@couet
Copy link
Member

couet commented Mar 29, 2023

I see it also with master. Thanks to have reported.

@couet
Copy link
Member

couet commented May 24, 2023

This piece of code is the faulty one. It looks weird ... I do not really understand the logic right now.

@couet
Copy link
Member

couet commented May 24, 2023

Indeed there is similar code in PaintInit. It does not match. It should be similar I guess.

@couet
Copy link
Member

couet commented May 24, 2023

Fix here: #12876

@couet couet closed this as completed May 26, 2023
@github-actions
Copy link

Hi @couet,

It appears this issue is closed, but wasn't yet added to a project. Please add upcoming versions that will include the fix, or 'not applicable' otherwise.

Sincerely,
🤖

1 similar comment
@github-actions
Copy link

Hi @couet,

It appears this issue is closed, but wasn't yet added to a project. Please add upcoming versions that will include the fix, or 'not applicable' otherwise.

Sincerely,
🤖

@couet couet added this to Issues in Fixed in 6.30/00 via automation May 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
No open projects
Development

No branches or pull requests

2 participants