+1 800 256 3608 (toll-free in North America) or +49 7531 90 60 10| service@combit.com

Need to disable ribbon in the preview

preview

(Josef Kokes) #1

I need to resolve a user request:

When I start my application and request a preview to be printed, I get a preview window with a simple small toolbar at the top (OK). Then I open the designer and get a designer with a ribbon bar (OK). Then whenever I request another preview, that preview window will have a ribbon bar rather than a toolbar. I need to disable this - the ribbon is perfectly fine for the designer, but for a preview, I always want a toolbar. How can I do that? Searching for “ribbon” in the source codes or the programmer’s manual, I cannot find anything relevant. I tried disabling ribbon using LlSetOption(LL_OPTION_RIBBON_DEFAULT_ENABLEDSTATE, 0) before every preview, but it did not help.

Any idea what should I do, except convince the user to start liking the ribbon?

Josef


(Josef Kokes) #2

LL version 22, with Delphi VCL.


(Günther Schwarze) #3

Hi Josef,

A simple way might be to have your own preview window using the preview control (that should be available for Delphi as well). Other than that, I’d look in the registry for some ribbon related settings, probably somewhere at HKCU\Software\combit\CMBTLL<YourApplication>

G.


(Josef Kokes) #4

Hi Gunter,

thank you for the answer. I was, however, looking for a solution somewhere in the area of LLSetOptions or the options of the components - List & Label already supports the toolbar mode, it’s just that the mode gets disabled after the designer got shown. If I never display a designer, the preview works just fine. Surely there must be some way to enforce a consistent behavior - there’s no good reason why should the appearance of the standard preview window depend on whether the designer was used or not.

Josef


(Josef Kokes) #5

Unfortunately, I can’t find any relevant setting in the registry :-(. I thought I had it with value Ribbon in HKEY_CURRENT_USER\SOFTWARE\combit\cmbtll<app>\Toolbars\Preview, but it doesn’t actually have any effect on my problem.


(Günther Schwarze) #6

Setting HKCU\Software\combit\cmbtll\<AppName>\Designer.Ribbon.Active to F does work for me. So it seems the setting for the Designer and the preview are somehow glued together.

In order to have the correct default right from the start, you should also set LL_OPTION_RIBBON_DEFAULT_ENABLEDSTATE to 0.