rounded-corners

Java Swing rounded border for Jtextfield

天大地大妈咪最大 提交于 2019-12-12 08:12:01
问题 When I do : LineBorder lineBorder =new LineBorder(Color.white, 8, true); jTextField2.setBorder(lineBorder ); I get this result like: How can I have rounded borders without the squared corners visible and the text half cut ? Thank you very much. Best regards 回答1: You can override JTextFiled build your own Rounded corner JTextField . You have to override it's paintComponent() , paintBorder() , and contains() methods. You need to draw roundRect as the shape of text field. Example: public class

How do I add a UIImage to grouped UITableViewCell so it rounds the corners?

微笑、不失礼 提交于 2019-12-12 07:54:38
问题 I'm trying to add images to table cells in a grouped UITableView but the corners of the images are not clipped. What's the best way to go about clipping these (besides clipping them in Photoshop? The table contents are dynamic.) For example, the first image in a table would need the top left corner rounded only. 回答1: This was my solution, which could use a little refactoring: void addRoundedRectToPath(CGContextRef context, CGRect rect, float ovalWidth, float ovalHeight, BOOL top, BOOL bottom)

Rounded avatar ruby on rails

守給你的承諾、 提交于 2019-12-12 04:29:56
问题 I would like to have my avatars that my users upload to be round on my rails app project for Udemy. The image still comes out square the way it was uploaded. below is my show.html.erb file <div class="row"> <div class="col-md-3 text-center"> <div class="avatar"><%= image_tag @user.profile.avatar.url %></div> </div> <div class="col-md-6"> <h1><%= @user.profile.first_name %> <%= @user.profile.last_name %></h1> <h3><span class="job_title_icon"><%= job_title_icon %></span> <%= @user.profile.job

2 Round Corners of a UIView in UITableViewCell not working

℡╲_俬逩灬. 提交于 2019-12-12 03:36:28
问题 I am trying to create round corners for a UIView with in a custom TableViewCell. The problem is when the table view loads, it only rounds the Top Left corner of the view and not the bottom one. Now when i scroll the table view little bit, it rounds the bottom left part of the view as well. I have tried every possible method but i can't get my head around it. I am also attaching the screenshots as well as copying the code. Thanks The code that i am using in the custom view cell class is below.

Rounded rectangle in RDLC Report

烂漫一生 提交于 2019-12-12 01:45:42
问题 I have drawn rectangles and tables in my RDLC report. But I want to show rectangle's rounded corners and Black color of Table cell borders. Is there any way to do it? Or anyway I can use CSS styles in RDLC report elements? 回答1: You can try to use CSS on the elements. The ID of the ReportViewer Div is usually "1_" whatever the instance name is, meaning if you have something like: private void Page_Load(object sender, System.EventArgs e) { MyReportViewer.ShowBackButton = false; MyReportViewer

CSS3 double rounded border, is it possible without 2 divs?

天涯浪子 提交于 2019-12-11 17:31:19
问题 I was wondering if it was possible to create a double rounded border without nesting DIV's? See my example here: http://jsfiddle.net/eXDjL/ The first box is rounded, but the ouline stays square, the second box has no rounded corners but shows the borders how I want them. I know there is a -moz-outline-radius property , but anything for the other browsers? If not I guess I'll just stick with two divs. 回答1: To mimic different color borders you can use box-shadow - http://jsfiddle.net/eXDjL/3/

Only bottom corners rounded

↘锁芯ラ 提交于 2019-12-11 11:13:18
问题 I have a textview below a tableView, both same Backgroundcolor so it appears as if its one View. Now I want the bottom corners of the textview to be rounded, but not the top ones (cause then you could see a gap between the textview and tableview). I found some answers on here, but somehow it just makes the bottom left corner rounded, not the right one? I also tried changing the order inside the Array, didn't work. Then I tried just the left corner, worked. But only the right corner didn't

Round corners on images using Java and JAI

China☆狼群 提交于 2019-12-11 09:56:59
问题 We're using JAI (https://jai-imageio.dev.java.net/) to scale and crop images in Java. We would like to create round corners on our images. How do we do that? The images are JPG and PNG. I would think it's easier to do this with JPGs? The image is a PlanarImage from JAI PlanarImage src = JAI.create(...,...); which can be transformed to a java.awt.Graphics object Has anyone done this before? 回答1: PNG supports a transparent alpha channel, but JPG does not. So, for JPG you would have to also pick

How I can do a button with left/right side as rounded as circle

老子叫甜甜 提交于 2019-12-11 00:33:23
问题 I'm trying to do a button with the sides rounded, but when I change the size of screen the button sides left to be rounded as circles, doesn't mantain the aspect ratio (I think). I want to have the next togglebutton in everysize. How I can do an XML with the sides rounded for every resolution? I've read this, but is not a solution (How to make the corners of a button round?) 回答1: The other answers are correct... almost: if you will set corners to some value (let's say 20dp), but your button

jQuery UI Tabs - Rounded Tab Corners in IE

余生颓废 提交于 2019-12-11 00:24:48
问题 I'm trying to switch from AjaxControlToolkit to jQuery UI tabs for a fairly simple tab element. I'm 99% there with CSS and theming, but I'm running into a wall attempting to get rounded corners on the tabs in IE. jQuery UI provides the styles needed for rounded tabs in better browsers, but it might be a deal-breaker if we can't get them in IE. I would really hate to have to keep using the Toolkit, and would also prefer not to bring in a different plugin to do the tabs (although this is an