QT widgets, rounded selected corner only - qt

I can set a QT QPushButton to rounded button by setting "border-radius" in style sheet, however i just want to set only the right edge (top and bottom right) corner of the button to rounded. How to do it?

You can set border-top-right-radius and border-bottom-right-radius in style sheet.

Related

ng2 pdf-viewer: Some text opacity decreases when zooming in

implemented custom zoom in and zoom out functionality. On clicking zoom in i increase [zoom] value to 0.25. On clicking zoom out i decrease [zoom] value to 0.25.
pdf container div has width of col-md-6 and max-height is set to 950px.
overflow-x and overflow-y are set to scroll.
On clicking zoom in when horizontal scroll bar appears then text after scrollbar shaded up.
How to solve this?
solved this by using background-color in rgba
background-color:rgba(255,255,255,255);

How to keep styles while dragging an element?

My problem is, I have a draggable element, that has some styling. When i'm dragging it, it doesn't keep all the styles, some of them disappear WHILE the element is being dragged.
Specifically the one I need to keep is box-shadow.
Fiddle here
Standard box-shadow style:
.fixed-red-bg {
box-shadow:10px 5px 5px 5px;
}
How do I not lose my box shadow while dragging that element? Optionally, is there any other style, that is not lost while dragging, that can be used to mimic a depth effect?
On Chrome and Firefox, when you drop the red box into the drop area, the shadow does appear to remain. However, while you are dragging it Chrome will usually drop the shadow. I recall this problem being reported a few years ago but I don't believe it's been resolved?
While someone else may have a suitable fix using css, what you can do is make a semi-transparent .png image as the shadow, and position it under the object using the pseudo before

CSS3 - image corner hide behind border radius

How to hide square image (90 degree corner) behind a content cox with border radius.
This is for iPhone mobile app.
align top http://www.kerrydeaf.com/corner.png
I had this problem when the border-radius property was first announced by the W3C. You've got to solutions: first, use background-image to set the image as your div's background.
Second, would be using <img class="my-class-rounded-corners" src="myimage">, appending a class to an <img> tag rather than a div, then setting rounded corners as a property of that class.

Drop shadow filter offsets border in IE 8

If you use Shadow filters in IE8 on a DIV, the DIV's contents will be offset by the shadow. If you give that DIV a border, this leads to weird behaviour. This is how it looks
The whole contents and the shadow go out of bounds of the div, having an offset to the border. Is there any way to correct this, or even to fake-correct this, at least getting the border back in position?

Button border appearing within object height

This isn't a major issue as it can easily be tweaked with a bit of css - just something I'm interested to know. Why does the border appear within the height of a button element instead of outside, as per box model? In the example below I have a button element and an anchor element. Both height 30px, with a 1px border. However the button element appears 2px shoter than anchor (which displays correctly at total height 32px).
http://jsfiddle.net/Y9Rv7/1/
Thanks
Adding this to the style should resolve your problem
box-sizing: content-box
This will cause the element to render as you want. I believe that by default buttons render with the border-box behaviour wich causes padding and borders to be added inside the box.

Resources