X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FcreaDevManagerLib%2FwxCDMFileDescriptionPanel.cpp;h=81768a97aaaded19ee78ee99074362f539c84998;hb=71c071fbb1e2af618f6caa489351b966e1a54b1a;hp=fac03fa10c5474b077157443b2266f9b7a85dd33;hpb=11ddb2799cdae68c7220b71e6836b97498b6ce62;p=crea.git diff --git a/lib/creaDevManagerLib/wxCDMFileDescriptionPanel.cpp b/lib/creaDevManagerLib/wxCDMFileDescriptionPanel.cpp index fac03fa..81768a9 100644 --- a/lib/creaDevManagerLib/wxCDMFileDescriptionPanel.cpp +++ b/lib/creaDevManagerLib/wxCDMFileDescriptionPanel.cpp @@ -75,6 +75,10 @@ bool wxCDMFileDescriptionPanel::Create( ) { wxPanel::Create(parent, id, pos, size, style); + // this part makes the scrollbars show up + this->FitInside(); // ask the sizer about the needed size + this->SetScrollRate(5, 5); + this->file = file; CreateControls(); return TRUE; @@ -124,16 +128,16 @@ void wxCDMFileDescriptionPanel::CreateControls() wxStaticText *pLength = new wxStaticText(propertiesPanel, -1, wxT("File Size")); wxStaticText* pLocationtc = new wxStaticText(propertiesPanel, wxID_ANY, crea::std2wx(this->file->GetPath())); - pLocationtc->SetMaxSize(wxSize(350,-1)); + pLocationtc->SetMaxSize(wxSize(300,-1)); int lgth = this->file->GetLength(); std::stringstream ss; ss << lgth / 1024; std::string lgths = ss.str() + " KB"; wxStaticText* pLengthtc = new wxStaticText(propertiesPanel, wxID_ANY, crea::std2wx(lgths)); - propertiesGridSizer->Add(pLocation, 0, wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL); + propertiesGridSizer->Add(pLocation, 0, wxALIGN_RIGHT | wxALIGN_TOP); propertiesGridSizer->Add(pLocationtc, 1, wxEXPAND); - propertiesGridSizer->Add(pLength, 0, wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL); + propertiesGridSizer->Add(pLength, 0, wxALIGN_RIGHT | wxALIGN_TOP); propertiesGridSizer->Add(pLengthtc, 1, wxEXPAND); propertiesGridSizer->AddGrowableCol(1,1);