shapes

Selecting regions of an image in a jQuery wizard

隐身守侯 提交于 2019-12-24 10:35:39
问题 I'm creating a wizard (really, a glorified survey) using jQuery Wizard Redux. I have several images (created in Illustrator) which I want the user to select from, which would act as their "submission" for each step of the wizard. e.g. this world map I made in Flash Catalyst. (sidenote: I want the wizard to be viewable on an ipad/iphone so I'm shying away from Flash at this point) Is it possible to create something similar using jQuery/Javascript? Some of the regions are quite complex - for

when selected add border shape for textView and editText ,

[亡魂溺海] 提交于 2019-12-24 07:57:33
问题 I want to create a border shape for TextView and EditText, and show it when a view is selected. Just like in this picture. 回答1: You should use drawable selector to achieve your UI. First create a background_edit_text_default.xml which is the background of EditText when it is not selected by users. <?xml version="1.0" encoding="utf-8"?> <shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle"> <stroke android:width="1dp" android:color="#333D46" /> <padding

when selected add border shape for textView and editText ,

懵懂的女人 提交于 2019-12-24 07:57:09
问题 I want to create a border shape for TextView and EditText, and show it when a view is selected. Just like in this picture. 回答1: You should use drawable selector to achieve your UI. First create a background_edit_text_default.xml which is the background of EditText when it is not selected by users. <?xml version="1.0" encoding="utf-8"?> <shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle"> <stroke android:width="1dp" android:color="#333D46" /> <padding

How do I draw thick lines with closely spaced points properly with Java2D graphics?

China☆狼群 提交于 2019-12-24 00:35:50
问题 I'm trying to draw maps using Java2D. When my map is zoomed out my roads are full of drawing artefacts. This is a small part of the screen when drawing a complete US state: This is a similar section of the road when zoomed closer in: The line style used is a solid blue line with width scaled to be equivalent to 2 pixels. I've tried various rendering hints and line joining rules and nothing seems to help. I'm using Open JDK 1.7 on a Mac running the OS/X 10.8 and this is also reproducible on a

D3 Arc With Chevron Shaped End

心不动则不痛 提交于 2019-12-23 20:35:58
问题 I've drawn an arc using D3.js which by default has square shaped ends. var arc = d3.arc() .innerRadius(0) .outerRadius(100) .startAngle(0) .endAngle(Math.PI); d3.selectAll('svg') .append('path') .attr('d', function() { return arc(); }); How can I draw an arc with a chevron shape on one end of it. 回答1: I would just use d3's path generator with an SVG marker. Add any shape to any path. Edit the "ends" by editing the marker definition. Use D3 path generator to define your arc (or any path). It's

how to get the relative position of shapes within a worksheet

倖福魔咒の 提交于 2019-12-23 20:26:47
问题 If you think of cells, we know logically that Row 2 is higher than row 100. However If I had two shapes (lets say circles) how do I determine which one is higher than the other, or further left than the rest? UPDTAE Where is the Object model for all Objects and methods / attributes for things like 1. charts >> The Top left 回答1: Here is some code to display the row for each Shape: Sub dural() Dim s As Shape, mesage As String For Each s In ActiveSheet.Shapes mesage = mesage & vbCrLf & s.Name &

How to add a half circle at the bottom middle of my header?

偶尔善良 提交于 2019-12-23 15:03:17
问题 Here is how I want it to look: I realize this is an ugly mockup and obviously when I do it for real the proportions will look better, but I am wondering how you would go about doing this with CSS. fiddle is here http://jsfiddle.net/bU3QS/1/ <div class="header"> </div> .header { position: fixed; top: 0; left: 0; width: 100%; background: #000; z-index: 10000; height: 110px; overflow: hidden; } 回答1: Use the :after pseudo element: .header:after { content: ''; position: absolute; background: black

I am having an issue with drawing a cross with JavaFX

一笑奈何 提交于 2019-12-22 08:30:57
问题 I am trying to write code that will draw 3 shapes diagonally across a grid. The first two shapes are a square and a circle, which I was able to do. The third shape, however, is giving me some grief. I am supposed to draw a cross (T version, not X), and every time I write out the code it comes out looking like a sideways, ⊢. I know I am just missing something simple, but I would really appreciate the help! Here is the full code for my Shapes program. import javafx.application.Application;

What is the android equivalent of java.awt.geom.Area?

与世无争的帅哥 提交于 2019-12-22 04:35:29
问题 I want to build complex shapes as the intersection of two circles and a rectangle. After researching a bit, java.awt.geom.Area class seems perfect for this task. I was dismayed, however, when I discovered that the awt package doesn't come with the android SDK. Does anyone know of any alternatives for android that allows me to create complex shapes by defining the union and intersection of simpler shapes? Note: Using graphics clipping to draw the shape doesn't work because I don't just want to

How to print out an X using nested loops

好久不见. 提交于 2019-12-22 01:04:23
问题 I have searched through to find a simple solution to this problem. I have a method called printCross(int size,char display) It accepts a size and prints an X with the char variable it receives of height and width of size. The calling method printShape(int maxSize, char display) accepts the maximum size of the shape and goes in a loop, sending multiples of 2 to the printCross method until it gets to the maximum. Here is my code but it is not giving me the desired outcome. public static void