X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=src%2FgdcmHeaderEntry.cxx;h=514a591eace2439f0b913a6b01cc2771bc08f765;hb=a547ed6d41e444153f4bea38c47810fe7f50d88e;hp=e53120744a3385ac0f75921753cd04a5ca6439f3;hpb=8d4184fc7129f85d9ec384a3c7b9c5928a1f5b5e;p=gdcm.git diff --git a/src/gdcmHeaderEntry.cxx b/src/gdcmHeaderEntry.cxx index e5312074..514a591e 100644 --- a/src/gdcmHeaderEntry.cxx +++ b/src/gdcmHeaderEntry.cxx @@ -13,6 +13,9 @@ #endif #include // for std::ios::left, ... + +#define MAX_SIZE_PRINT_ELEMENT_VALUE 10000 + //----------------------------------------------------------------------------- // Constructor / Destructor /** @@ -48,7 +51,7 @@ void gdcmHeaderEntry::Print(std::ostream & os) { d2 = _CreateCleanString(v); // replace non printable characters by '.' if (printLevel>=2) { s << "lg : "; - lgth = GetReadLength(); + lgth = GetReadLength(); // ReadLength, as opposed to UsableLength if (lgth == 0xffffffff) { sprintf(st,"x(ffff)"); // I said : "x(ffff)" ! s.setf(std::ios::left); @@ -76,12 +79,17 @@ void gdcmHeaderEntry::Print(std::ostream & os) { if (printLevel>=1) { s.setf(std::ios::left); s << std::setw(66-GetName().length()) << " "; - } + } + + s << "[" << GetName()<< "]"; + - s << "[" << GetName()<< "]"; - if( (GetLength()<64) || (printLevel>=3) ) + + if( (GetLength()=3) || + (d2.find("gdcm::NotLoaded.") < d2.length()) ) s << " [" << d2 << "]"; - else + else s << " [ gdcm::too long for print (" << GetLength() << ") ]"; // Display the UID value (instead of displaying the rough code)