Page 1 of 1

Custom preview in designer

Posted: Fri Jun 17, 2016 8:34 am
by Tobias
Hi,

is it somehow possible to provide a custom preview to the designer?
I would like to add a preview which displays the DotMatrix-Output with ESC-formatting codes in a WYSIWYG-way.

Tobias

Re: Custom preview in designer

Posted: Fri Jun 17, 2016 10:06 am
by HighAley
Hello, Tobias.

You could change the Preview Mode property of the report to Dot-Matrix.

Thank you.

Re: Custom preview in designer

Posted: Fri Jun 17, 2016 10:12 am
by Tobias
Sure, I know that, but it's not what I need

I need the preview to show the Dot-Matrix-Output with ALL ESC-formatting codes as WYSIWYG. (Bold, Italic, Centered, inverse, double-height and double width fonts and so on).
I know, that Reports.Net can't do this out-of-the-box, so I would like to add my own preview rendering. I just would like to know if it is somehow possible to hook my own preview-code into the Reports.Net designer.

Or maybe there is a way to add a custom toolbar-button to the designer which will call back into my code so I can open a custom preview window.
Something like that.

Re: Custom preview in designer

Posted: Fri Jun 17, 2016 1:11 pm
by HighAley
Hello, Tobias.

If you have our source code, you could replace our Dot-Matrix preview.

Or you could try to add a button like in this topic.

Thank you.

Re: Custom preview in designer

Posted: Fri Jun 17, 2016 1:42 pm
by Tobias
Thanks.

I have the source, but I would like to avoid using a fork.

I've already tried what is described in the topic you linked to, but I don't see a toolbar button appear anywhere. Whe should I see it?

I did:

Code: Select all

            StiStandardToolbarService stdToolbar = StiStandardToolbarService.GetService();
            stdToolbar.AddToolButton("CAN YOU SPOT ME?????", (sender, eventArgs) => { });
            var stiReport = new StiReport();
            stiReport.Design();

Re: Custom preview in designer

Posted: Fri Jun 17, 2016 3:57 pm
by Tobias
Ok, I think this just doesn't work with an UI theme that uses ribbons, right?

Re: Custom preview in designer

Posted: Mon Jun 20, 2016 11:08 am
by HighAley
Hello.

Yes, in WinForms we use third-party component that creates Ribbon interface.

Thank you.

Re: Custom preview in designer

Posted: Mon Jun 20, 2016 12:00 pm
by Tobias
Ok.
I guess the WPF version of reports.net doesn't have an extension point for a custom preview either?

Re: Custom preview in designer

Posted: Tue Jun 21, 2016 9:01 am
by HighAley
Hello.

There is a StiWpfDotMatrixViewerControl that you could use in WPF.
And you could add buttons there.

Thank you.