3

I have a QComboBox that shows a selection arrow by default on the left when clicked - snapshot attached below.

enter image description here

My stylesheet is as below

#define PROFILE_PAGE_COMBOBOX_CSS_ACTIVE " \
    QComboBox { \
        background:white; \
        border:1px solid gray \
    } \
    QComboBox::down-arrow { \
        image: url(:/images/profilecomboboxdropdown.png); width:15px; height: 15px; \
    } \
    QComboBox::drop-down { \
        subcontrol-origin: padding; \
        subcontrol-position: right; \
        width: 15px; \
        height: 15px; \
        border:0px; \
        padding-right:8px; \
    } \
    QComboBox QAbstractItemView { \
        border: 0px; \
        padding: 1px; \
        background-color: #ffffff; \
        color: gray; \
        selection-background-color: #ffffff; \
        selection-color: blue; \
    } \
"

this->m_CountryEdit->setStyleSheet(PROFILE_PAGE_COMBOBOX_CSS_ACTIVE);

How can I get rid of this selection arrow? I am using Qt 4.7.4 on both Mac and Windows

S B
  • 8,134
  • 10
  • 54
  • 108

1 Answers1

0

It's a mac-specific issue and there sseems to be several ways to live with it - make selection mark to go offscreen with stylesheet positioning - make it look less ugly by removing the border around (it's a question of removing a style that makes that border to show) - so not set 'surrent' item in combobox probably

Jerry
  • 143
  • 4