Skip to content
Snippets Groups Projects
Commit 7eb9879f authored by Olivier Couet's avatar Olivier Couet
Browse files

- A Square TCanvas saved in batch mode in a root file

  and then displayed again in interactive mode was not
  square anymore.


git-svn-id: http://root.cern.ch/svn/root/trunk@36278 27541ba8-7e3a-0410-8455-c3a389f83636
parent e5c8a444
No related branches found
No related tags found
No related merge requests found
......@@ -790,8 +790,14 @@ void TCanvas::Draw(Option_t *)
}
if (old) { gROOT->GetListOfCanvases()->Remove(old); delete old;}
if (fWindowWidth == 0) fWindowWidth = 800;
if (fWindowHeight == 0) fWindowHeight = 600;
if (fWindowWidth == 0) {
if (fCw !=0) fWindowWidth = fCw+4;
else fWindowWidth = 800;
}
if (fWindowHeight == 0) {
if (fCh !=0) fWindowHeight = fCh+28;
else fWindowHeight = 600;
}
fCanvasImp = gGuiFactory->CreateCanvasImp(this, GetName(), fWindowTopX, fWindowTopY,
fWindowWidth, fWindowHeight);
fCanvasImp->ShowMenuBar(TestBit(kMenuBar));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment