Posts

java - Graphics.clearRect() won't work for me -

Hi, I have searched the web for a while but the solution to solve me does not work for me, so here is my problem I am creating graphs on my GUI using graphics and drawl (), which works perfectly for me - for the first time when I use my program in the same area I say to keep the graph, so it only spoils things. Public Zero Paint Free (Graphics G) {super.paintComponent (g); Int max = 100; G.clearRect (0, 0, 205, 200); & Lt; - g.drawRect (10, 10, 200, 200); G.drawString ("+ + Max, 0, 10)"; G Drline (5, 110, 10, 110); G.drawString ("0", 0, 275); ... attracting the actual graph here. Now it was the idea that every time I have to draw it that I keep a white surface for the first time, so it removes anything pulled earlier but it does not work. I'm new enough for graphics, please do not hesitate to comment if I am doing it completely wrong. Thanks Advance. / P> -Alex

CSS (or not) animated image it becomes transparent onmouseover and then becomes untransparent again -

heyo féoho gotta question, I have to create a picture which becomes slightly transparent (like opacity 0,4), then size Grows like 2x and then becomes unrestricted (Opacity 1) and the text does not convert that position to its position. img {opacity: 1; Width: 250; } Img: Hover {Opacity: 0.4; Filters: alpha (opacity = 40); Width: 500px; Transit-property: width; Transition period: 4s; } I created only one CSS code for size and transparency, although it is not known how to make it again opacity after my 4sec animation and it does not know How to create a text Very much after the image size increases Hello, I could not understand your problem properly. But here I think that you want something like that. HTML & lt; Img src = "http://t3.gstatic.com/images? Q = TBN: AN9 GCTCRT 41JVA 43 Blaz DOS5TigUCCsCXBS 1U6DBiHIPMGJ-OAR7S8X" AT & GT; CSS @keyframes lI {0% {Opacity: 1; Conversion: Scale (1);} 50% {Opacity: 0.4; Conversion: Scale (1.3);} 100% {...

c++ - Why use new and delete at all? -

I'm new to C ++ and I'm wondering why should I bother to use and delete new ones? It can cause problems (memory leaks) and I do not find that I should start a variable without the new operator only. Can anyone explain this to me? This specific question is difficult for Google. "post-text" itemprop = "text"> For historical and effective reasons, C ++ (and C) is clear and manual. Sometimes, you can allocate (or using S). However, this is not always possible, because The stack size is limited (depending on the platform, some kilobytes or some megabytes). Memory is not always required or it is such that you need to allocate memory, which is very free during the execution (or unnecessary) especially since it results in some functions (And the collar - or its collar - will release the memory). You should definitely read and in some languages ​​(Java, Okel, Haskell, Lisp, ....) or system, a GC is provided, and useless (more accurate Accessible ...

ruby - Diff between two time -

How is the difference between two times in Ruby calculated? For example: I have this time as a string time1 = '08: 00 'time2 =' 12: 00 ' Understand that time is 1 positive and time 2 is negative (seems like working hours, I work 8 hours a day, and 12 hours a day for another day Looks like), I want to do something like this: diff = time.parse (time1) - time.parse (time 2) time. (Difference) .gmtime.strftime ('% H:% M ') # Something like "-04: 00" is expected to be received at # but the result is "20:00" To understand what is wrong with your code, let's execute it one by one: ▶ time.preparation ('08: 00 ') - time. Parse ('12: 00 ') # = & gt; -14400.0 seconds, huh okay. ▶ Time. (Time.only ('08: 00 ') - Time. From (' 12: 00 ')) => 1969-12-31 21:00:00 +0100 Wow, Time.at There is no way of our dreams. Apart from this, I do not know the hours in format in the standard libr...

sql - How can I create TableNameColumnName alias' for SELECT * statement? -

मुझे निम्न आउटपुट होना है: टेबलकॉल्यूम 1 टेबलकॉल्यूम 2 ​​टेबलबीकोलमैन 1 टेबलबिल्ड 2 कुछ वैल्यू कुछ वैल्यू कुछ वैल्यू कुछ वैल्यू निम्नलिखित कथन के लिए: SELECT * AS ... से तालिकाए, टेबलब जहां TableA.Column1 = TableB.Column1 क्या SQL Server 2014 में यह संभव है? क्या मैं हासिल करना चाहता हूं, इसके लिए INFORMATION_SCHEMA.COLUMNS का उपयोग करना संभव है? आप की एक सूची जनरेट कर सकते हैं इस क्वेरी के साथ कॉलम: चुनें STUFF ((SELECT ',' + a.TABLE_NAME + '।' + A.COLUMN_NAME + 'ए' + a.TABLE_NAME + a.COLUMN_NAME सूचना विज्ञान से संपर्क करें I कॉलम के लिए एक WHERE TABLE_NAME = 'पटल (' ',' TYPE ') के लिए' टेबल नाम '। मूल्य ('। ',' VARCHAR (अधिकतम) '), 1, 1,' ')

How to connect to Oracle with datamapper jdbc adapter (in JRuby) and check connection? -

How to check the connection from the Oracle to the JDBC adapter (in jereb) and the connection? I do not understand the documentation: D If you have some examples, please give me Adapter = DataMaper.setup (: default, 'oracle: // user: password @ host /' ORCL ') z = adapter.select (' Select from 1 to double ' )

ios - MKMapViewAnnotation Image from custom image different for many pins -

I'm trying to create several pins from a database of locations, with each custom image. Images base are passed to the server in the 64 format, I am able to create a UIImage to base64 data, but I can not upload images as icons instead of pins for each annotation Are there. Any ideas how can I do this? I tried to help in following these SO terms, but they can only make one preset one, I can not understand how all of these can be edited Any thoughts? Here is my code to pin / annotation, anyone interested: function mapTheseCoordinates (Lat: Double, LNG: Double, username: NSString, full name: NSString) {go home = CLLocationCoordinate2D (Latitude: Latitude, Longitude: LNG) // 2 to period = MKCoordinateSpanMake (0.15, 0.15) to the area = MKCoordinateRegion (in the middle: space, period: period) mapView.setRegion (area , Animated: true) // give 3 annotations = MKPointAnnotation () annotation.setCoordinate (location) annotation.titl e = username nnotation.subtitle = compl...