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

ENH: Replace HTML_HYPERLINK_PREFIX_FOR_CGI with std::string argument #108

Closed
wants to merge 1 commit into from

Conversation

thewtex
Copy link
Contributor

@thewtex thewtex commented Aug 16, 2024

The dsr2html tool uses a hardcoded literal string as a hyperlink prefix for refrenced composite objects (images, waveforms, etc.) in rendering the Key Object Selection documents.

Replace this literal with a string argument that will be passed by a calling application / function.

@michaelonken here is a patch that would be helpful to upstream.

CC @jadh4v @fedorov

The dsr2html tool uses a hardcoded literal string as a hyperlink prefix
for refrenced composite objects (images, waveforms, etc.)
in rendering the Key Object Selection documents.

Replace this literal with a string argument that will be passed
by a calling application / function.
thewtex added a commit to thewtex/ITK that referenced this pull request Aug 16, 2024
The dsr2html tool uses a hardcoded literal string as a hyperlink prefix for refrenced composite objects (images, waveforms, etc.) in rendering the Key Object Selection documents.

Replace this literal with a string argument that will be passed by a calling application / function.

Pushed upstream: DCMTK/dcmtk#108
Copy link

@jadh4v jadh4v left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just one minor point, otherwise looks good.

const size_t flags) const
{
/* render reference */
docStream << "<a href=\"" << HTML_HYPERLINK_PREFIX_FOR_CGI;
docStream << "<a href=\"" << urlPrefixToCompositeObjects;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need to change these lines to this?

docStream << "<a href=\"" << urlPrefixToCompositeObjects.c_str();

Or the current one is fine?

@jriesmeier
Copy link
Member

Thank you for your contribution. I've already checked your proposed patch and applied it locally with a few modifications (e.g. regarding DCMTK conventions, missing API documentation, order of parameters). I will probably also add a new command line option to dsr2html that allows for specifying the URL prefix for hyperlinks to composite objects.

@jriesmeier
Copy link
Member

jriesmeier commented Sep 2, 2024

A brief interim report: It seems that I now managed to get rid of the warnings that were shown when compiled with gcc and option -Woverloaded-virtual. After some more testing, I will merge the changes to "testing" and then later to the "master" branch.

michaelonken pushed a commit that referenced this pull request Sep 5, 2024
Made URL prefix for hyperlinks to composite objects configurable. The
default behavior is to use the URL prefix http://localhost/dicom.cgi,
which is e.g. needed for DICOMscope.

Thanks to GitHub user "thewtex" (Matt McCormick) for the proposal and
the original patch. See GitHub pull request #108 for details.
@jriesmeier
Copy link
Member

I just pushed the changes I have made to the public DCMTK git repository. See commit bd3dd3e.

@jriesmeier jriesmeier closed this Sep 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants