I need to widen contour lines for TMarker objects with non-filled styles, e.g. (*),(x) or (o). SetMarkerSize() only increases size of marker, but not the thickness of its lines. gStyle->SetLineWidth() have no affect too.
Why I need this? When I prepare figures for publications or presentations, hollow markers looks too bad and too thin at my taste, its hard to read them. Currently I widen marker’s contour lines in gimp using erode filter, but this is no more than awesome forkaround.
Well, I had added the “bold marker” support to Qt-layer (to be propagated to the CERN repository yet)
The macro:void markers(int lineWidth=0)
{
// Display the table of markers with their numbers.
TMarker *marker = new TMarker();
marker->SetMarkerSize(3);
TText *text = new TText();
text->SetTextFont(62);
text->SetTextAlign(22);
text->SetTextSize(0.1);
char atext[] = " ";
Double_t x = 0;
Double_t dx = 1/12.0;
for (Int_t i=1;i<12;i++) {
x += dx;
sprintf(atext,"%d",i);
marker->SetMarkerStyle(i+ 1000*lineWidth);
marker->DrawMarker(x,.35);
text->DrawText(x,.17,atext);
sprintf(atext,"%d",i+19);
marker->SetMarkerStyle(i+19 + 1000*lineWidth);
marker->DrawMarker(x,.8);
text->DrawText(x,.62,atext);
}
delete marker;
delete text;
} with lineWidth=2 produces the output attached. However, one should understand the limitation . The output may become strange with Qt-layer off . The postscript output may be strange too unless one creates the Qt-based implementation of TPostcript /TPDF classes.
[quote=“bircoph”]Thanks a lot!
Will this feature be available in the next root release?
Is the patch available somewhere? Anyway I usually build root from the source.[/quote]One can always complement his/her current ROOT version with the latest version of QtRoot plugin. One can always download and install it from root.bnl.gov/QtRoot/How2Install.html . The fix will be sent to CERN too.
You can use the lists.bnl.gov/mailman/listinfo/qt-root-l list to communicate the bugs and issues.