Greetings Monks,

I am using Strawbery Perl 5.24 on a Win 7 platform with Tkx to render a GUI.

I have a similar question to SOLVED - TK: How to change color of readonly BrowseEntry, except that I am using Tkx, not Tk. I am using new_ttk__combobox and setting state to read only so the user cannot edit the options.

Currently the disabled state is grey, but I would like it to be white, to match the dialog background, to give the user the impression that the widget as a whole is still 'active'. I see no method for doing this in the documentation for the combobox widget.

I have looked at BrowseEntry and JBrowseEntry in Tk. They are excellent and would more than fulfill the requirement, but I am not aware of a way of using them in Tkx after having re-read the Tkx manual and the available tcl namespace. I have also looked at tk___optionMenu but my use of it has so far thrown up odd errors to do with re-using the name of a parent widget.

Thanks in advance for your help!


In reply to Setting disabled background on Tkx combobox widget by v4169sgr

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.