scaletransform

d3 getting invert value of Band Scales

假如想象 提交于 2019-11-30 04:18:04
问题 i am writing a Gantt Chart using d3 i have xScale with Time Scale(Time) this.xScale = d3.scaleTime() .domain([this.startDate,this.endDate]) .range([0,this.getWidth()]); and yScale as Band Scale (Resources) this.yScale = d3.scaleBand() .domain(resources.map(function(res){ return res.res_num; })) .rangeRound([0,this.getHeight()]) .paddingInner(.3) Problem is i need to drag and drop the task( SVG Rect) from one resource to another resources When i drag i am using the transfrom so its moving on

wpf scale to textBox, textBox can not display cursor when i click textBox

故事扮演 提交于 2019-11-29 16:20:41
First, I Zoom(ScaleTransform) the TextBox , then mouse to click on the TextBox . Sometimes can display the cursor, and sometimes can notdisplay the cursor. Looking for a solution to solution to the problem. I hope that I can show the cursor after I scale the TextBox . <Grid> <StackPanel> <TextBox Width="200"></TextBox> <TextBox Width="100"></TextBox> <TextBox Width="300"></TextBox> <TextBox Width="100"></TextBox> <TextBox Width="100"></TextBox> <TextBox Width="100"></TextBox> </StackPanel> <Grid.LayoutTransform> <ScaleTransform ScaleX="0.3" ScaleY="0.65"></ScaleTransform> </Grid

wpf scale to textBox, textBox can not display cursor when i click textBox

依然范特西╮ 提交于 2019-11-28 10:21:36
问题 First, I Zoom(ScaleTransform) the TextBox , then mouse to click on the TextBox . Sometimes can display the cursor, and sometimes can notdisplay the cursor. Looking for a solution to solution to the problem. I hope that I can show the cursor after I scale the TextBox . <Grid> <StackPanel> <TextBox Width="200"></TextBox> <TextBox Width="100"></TextBox> <TextBox Width="300"></TextBox> <TextBox Width="100"></TextBox> <TextBox Width="100"></TextBox> <TextBox Width="100"></TextBox> </StackPanel>

Three.js: How to flip normals after negative scale

爷,独闯天下 提交于 2019-11-28 01:18:07
I have cloned and than flipped an object using negative scale, which causes my single sided faces to inverse. My question is, how can i flip the normals too? I don't want to use material.side = THREE.DoubleSide, for reasons: 1) didn't work properly (some shades are drawn from inside) and 2) wanna keep as much performance as possible. So DoubleSide isn't an option for me. Thats how my object if flipped. mesh.scale.x = - scale_width; Thanks in advance! WestLangley I would advise against negative scale for a whole host of reasons, as explained in this link: Transforming vertex normals in three.js

WPF for LCD screen Full HD

主宰稳场 提交于 2019-11-27 21:44:56
I am developing a WPF application that will be displayed in a Full-HD LCD screen (42 inch). In addition, I need to accommodate the controls in absolute positions. In the development environment I can not see a window in length 1920x1080 (this is the fixed resolution of the targeted screen). What is the best practice to accomplish this task? WPF uses Device Independent Units for specifying width/heights/positions/thicknesses, etc. 1 DIU/DIP = 1 physical pixel when your screen DPI is set to 96dpi.....but 1 DIU = a different number of physical pixels when the DPI is not 96dpi. If you use a Canvas

Transform only one axis to log10 scale with ggplot2

一笑奈何 提交于 2019-11-27 11:13:34
I have the following problem: I would like to visualize a discrete and a continuous variable on a boxplot in which the latter has a few extreme high values. This makes the boxplot meaningless (the points and even the "body" of the chart is too small), that is why I would like to show this on a log10 scale. I am aware that I could leave out the extreme values from the visualization, but I am not intended to. Let's see a simple example with diamonds data: m <- ggplot(diamonds, aes(y = price, x = color)) The problem is not serious here, but I hope you could imagine why I would like to see the

Scale items with iCarousel

随声附和 提交于 2019-11-27 11:00:09
问题 I was trying to use iCarousel for one my solutions, I need to achieve something like the image below It should be exactly the way iCarouselOptionFadeMin iCarouselOptionFadeMax iCarouselOptionFadeRange iCarouselOptionFadeMinAlpha works using - (CGFloat)carousel:(iCarousel *)carousel valueForOption:(iCarouselOption)option withDefault:(CGFloat)value I tried to create a function exactly like - (CGFloat)alphaForItemWithOffset:(CGFloat)offset I discovered that it cane be done using offset values,

Pulsating button animation in Android

感情迁移 提交于 2019-11-27 06:20:34
问题 I'm working with a Voice recognition application and I want to make my play/stop button "pulse" when it's recording. Something like this: I have tried to make a ScaleAnimation, doing the button grow, but of course, it makes grow all the button. public static ObjectAnimator pulseAnimation(ImageView target){ ObjectAnimator scaleDown = ObjectAnimator.ofPropertyValuesHolder(target, PropertyValuesHolder.ofFloat("scaleX", 1.1f), PropertyValuesHolder.ofFloat("scaleY", 1.1f)); scaleDown.setDuration

WPF for LCD screen Full HD

折月煮酒 提交于 2019-11-27 04:32:37
问题 I am developing a WPF application that will be displayed in a Full-HD LCD screen (42 inch). In addition, I need to accommodate the controls in absolute positions. In the development environment I can not see a window in length 1920x1080 (this is the fixed resolution of the targeted screen). What is the best practice to accomplish this task? 回答1: WPF uses Device Independent Units for specifying width/heights/positions/thicknesses, etc. 1 DIU/DIP = 1 physical pixel when your screen DPI is set

Three.js: How to flip normals after negative scale

只谈情不闲聊 提交于 2019-11-26 21:52:40
问题 I have cloned and than flipped an object using negative scale, which causes my single sided faces to inverse. My question is, how can i flip the normals too? I don't want to use material.side = THREE.DoubleSide, for reasons: 1) didn't work properly (some shades are drawn from inside) and 2) wanna keep as much performance as possible. So DoubleSide isn't an option for me. Thats how my object if flipped. mesh.scale.x = - scale_width; Thanks in advance! 回答1: I would advise against negative scale