Id
int64
1.68k
75.6M
PostTypeId
int64
1
2
AcceptedAnswerId
int64
1.7k
75.6M
ParentId
int64
1.68k
75.6M
Score
int64
-60
3.16k
ViewCount
int64
8
2.68M
Body
stringlengths
1
41.1k
Title
stringlengths
14
150
ContentLicense
stringclasses
3 values
FavoriteCount
int64
0
1
CreationDate
stringlengths
23
23
LastActivityDate
stringlengths
23
23
LastEditDate
stringlengths
23
23
LastEditorUserId
int64
-1
21.3M
OwnerUserId
int64
1
21.3M
Tags
sequence
3,747,591
1
3,749,489
null
0
734
So now I want to make Estonian wordlist ~about 20m unique words in lowercase. To get input for wordlist, [corpus of Estonian](http://www.keeletehnoloogia.ee/projektid/koondkorpus/koondkorpus?set_language=et) can be used. Corpus files are in Text Encoding Initiative (TEI) format. I tried using regex to find the words. This is what I made: it's inefficient, mcv is all messed up, it brakes if hashset of words can't fit in memory, it's not aware of inputs encoding - so probably letters like š make problems, it does not show estimated completion time, some controls have default names and some don't, it does not use multitasking (not sure if it should), it uses some weird fixes and lots of locking interface so that it would appear not 'frozen'. At least its so short, that you hardly notice there are no comments. Upside is, that it can almost read words without many mistakes, from .tei, .txt, .csv, smgl, xhtml or any a like format inputs. Now you know what I want to do, how I have tried doing it (with what problems), and again I'm just trying to find out how to do it (with minimal manual labor). Image example: ![alt text](https://i.stack.imgur.com/vgwYi.png) Code example & [Gui](http://pastebin.com/SzZAZAmk): ``` using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; using System.Data.SqlClient; using System.IO; using System.Text.RegularExpressions; namespace Reader { public partial class Form1 : Form { public Form1() { InitializeComponent(); } private void listView1_DragEnter(object sender, DragEventArgs e) { if (e.Data.GetDataPresent(DataFormats.FileDrop, false) == true) { e.Effect = DragDropEffects.All; } } private void listView1_DragDrop(object sender, DragEventArgs e) { setguiLock(true); this.loading.Visible = true; ignorechecking = true; string[] files = (string[])e.Data.GetData(DataFormats.FileDrop, false); Dictionary<String, ListViewGroup> listviewgroups = new Dictionary<string,ListViewGroup>(); int filenamesi = 0; foreach (string file in files) { progresslabel.Text = string.Format("Progress: \t[ {0} / {1} ]", filenamesi++, files.Length); Application.DoEvents(); if (File.Exists(file)) { FileInfo ff = new System.IO.FileInfo(file); if (!listviewgroups.ContainsKey(ff.DirectoryName)) { listviewgroups.Add(ff.DirectoryName, new ListViewGroup(ff.DirectoryName, HorizontalAlignment.Left)); listView1.Groups.Add(listviewgroups[ff.DirectoryName]); } ListViewItem item = new ListViewItem(ff.Name); listviewgroups[ff.DirectoryName].Items.Add(item); item.Checked = true; item.SubItems.Add("" +((int)ff.Length/1024)+" KB"); // item.Group.Header = ff.DirectoryName; // listviewgroups[ff.DirectoryName].Items.Add(item); listView1.Items.Add(item); } } setguiLock(false); ignorechecking = false; this.loading.Visible = false; updatechecked(); } private void listView1_ItemChecked(object sender, ItemCheckedEventArgs e) { updatechecked(); } private bool ignorechecking = false; private void updatechecked(){ if (ignorechecking) return; long size = 0; int count = 0; foreach (ListViewItem item in this.listView1.Items) { if (item.Checked) { count++; size += Int32.Parse(item.SubItems[1].Text.Split(" ".ToArray())[0]); } } this.text1.Text = ""+count; this.text2.Text = ""+size + " KB"; } private void putHashset(HashSet<string> d, string filename) { StringBuilder sb = new StringBuilder(); foreach (string key in d) sb.Append(key).Append("\n"); File.WriteAllText(filename, sb.ToString()); } private HashSet<string> getHashset(string filename) { return new HashSet<string>(new Regex("\\n+").Split(File.ReadAllText(filename))); } private void removefilefromlistview(string fullfilename) { foreach (ListViewItem item in this.listView1.Items) { String file = item.Group.Header + "\\" + item.SubItems[0].Text; if (fullfilename.CompareTo(file) == 0) { item.Checked = false; this.listView1.Items.Remove(item); } } } private void starter(object sender, EventArgs e) { HashSet<string> filenames = new HashSet<string>(); StringBuilder data = null; setguiLock(true); this.time2.Text = ""; this.time1.Text = String.Format("{0:d/M/yyyy HH:mm:ss}", DateTime.Now); foreach (ListViewItem item in this.listView1.Items) { if (item.Checked) { String file = item.Group.Header + "\\" + item.SubItems[0].Text; if (File.Exists(file)) filenames.Add(file); } } string outputfile = output.Text; HashSet<string> words = null; if (File.Exists(output.Text)) words = getHashset(outputfile); else words = new HashSet<string>(); int filenamesnr = filenames.Count; int filenamesi = 0; foreach (String str in filenames){ progresslabel.Text = string.Format("Progress: \t[ {0} / {1} ]", filenamesi++, filenamesnr); Application.DoEvents(); data = new StringBuilder(System.IO.File.ReadAllText(str, Encoding.UTF7).ToLower()); data = data.Replace("&auml;", "ä"); data = data.Replace("&ouml;", "ö"); data = data.Replace("&uuml;", "ü"); data = data.Replace("&otilde;", "õ"); String sdata = new Regex(@"<(.|\n)*?>|%[a-zA-Z0-9]+?;|&[#a-zA-Z0-9]+?;").Replace(data.ToString(), ""); foreach (string word in new Regex("[^A-Za-zšžõäöüŠŽÕÄÖÜ]+").Split(sdata)) if(word.Length>1) words.Add(word); removefilefromlistview(str); } progresslabel.Text = "Progress:"; putHashset(words, outputfile); foreach (ListViewItem item in this.listView1.Items) if (item.Checked) { item.Checked = false; listView1.Items.Remove(item); } this.time2.Text = String.Format("{0:d/M/yyyy HH:mm:ss}", DateTime.Now); setguiLock(false); } private void setguiLock(bool value){ if(value){ this.Enabled = false; this.button1.Enabled = false; this.listView1.Enabled = false; this.output.Enabled = false; this.openoutput.Enabled = false; this.progresslabel.Visible = true; this.Enabled = true; }else{ this.Enabled = false; this.openoutput.Enabled = true; this.output.Enabled = true; this.listView1.Enabled = true; this.button1.Enabled = true; this.progresslabel.Visible = false; this.Enabled = true; } } private void button2_Click(object sender, EventArgs e) { if (!File.Exists(output.Text)) File.WriteAllText(output.Text, " "); System.Diagnostics.Process.Start(output.Text); } } } ```
How to build a wordlist
CC BY-SA 2.5
null
2010-09-19T21:43:56.533
2012-04-30T14:28:29.120
2012-04-30T14:28:29.120
79,298
97,754
[ "c#", "large-data-volumes" ]
3,747,730
1
3,747,765
null
15
3,608
Which one is the best practice and ? ## a) Type Table, Surrogate/Artificial Key Foreign key is from `user.type` to `type.id`: ![alt text](https://i.stack.imgur.com/eI7Bd.png) ## b) Type Table, Natural Key Foreign key is from `user.type` to `type.typeName`: ![alt text](https://i.stack.imgur.com/O9Tk4.png)
Relational database design question - Surrogate-key or Natural-key?
CC BY-SA 2.5
0
2010-09-19T22:27:07.943
2016-08-16T01:02:07.017
2010-09-19T23:25:34.567
242,769
242,769
[ "sql", "database-design", "data-modeling", "surrogate-key", "natural-key" ]
3,747,825
1
3,747,921
null
0
1,455
In Flash CS5 it seems like there's an option to import .swc files into the library, but as an RSL (runtime shared library). ![alt text](https://i.stack.imgur.com/cy3hi.png) What's the difference between this option (swc) and using a runtime shared library .swf file? Also, if you select a .swc file, and choose the "info" ("i") icon, there seems to be several options for .swc..."merged into code", "external", "runtime shared library": ![alt text](https://i.stack.imgur.com/lUS9Z.png)
How to share graphics between multiple .swf files? (Flash CS5)
CC BY-SA 2.5
null
2010-09-19T22:58:08.677
2010-09-20T15:13:31.283
2010-09-20T15:13:31.283
147,915
147,915
[ "actionscript-3", "rsl" ]
3,747,907
1
3,747,923
null
0
129
I am trying to learn asp.net 4 web app but playing around the web page template shipped in VS 2010. I clicked New Project --> (Web) ASP.Net Web Application I click ok. So now I am trying to manipulate the color of the blue header and the font color or the header text. But I am cant do it thru the css. Any ideas what is going on in the background? This is what I get in design time: ![DesignTime](https://i.stack.imgur.com/PE18e.jpg) This is what I get at runtime: ![alt text](https://i.stack.imgur.com/jhEkF.jpg)
Learning my way thru ASP.Net 4 basic web app
CC BY-SA 2.5
null
2010-09-19T23:32:37.890
2010-09-22T16:27:10.827
2010-09-22T12:43:09.980
279,521
279,521
[ "c#", "asp.net", "visual-studio-2010" ]
3,747,910
1
null
null
2
3,369
I am trying to put social buttons facebook and tweetmeme in our site. I liked the way it's done in yahoo sites. Please look [Yahoo Link](http://finance.yahoo.com/news/General-Motors-to-test-apf-122107979.html?x=0) I looked at yahoo code, but the implementation style is very difficult to understand. It would be great if someone can help me in html/css coding. Thanks. ## Update ![alt text](https://i.stack.imgur.com/czYPn.gif) This is the code I have so far.. The issues I am having is Yahoo customized the css by changing the facebook and tweetmeme css behavior. Please check the attached image and compare with it. The code I am using is --- ``` <a name="fb_share" type="button_count" share_url="http://www.yahoo.com" href="http://www.facebook.com/sharer.php">Share</a><script src="http://static.ak.fbcdn.net/connect.php/js/FB.Share" type="text/javascript"></script> <script type="text/javascript"> tweetmeme_url = 'http://www.yahoo.com'; tweetmeme_style = 'compact'; </script> <script type="text/javascript" src="http://tweetmeme.com/i/scripts/button.js"></script> ``` --- Please let me know, can we have exactly they have. I liked the look and feel of that. :) Thank You.
Align social buttons correctly
CC BY-SA 2.5
null
2010-09-19T23:32:54.777
2014-11-17T19:04:54.530
2010-09-20T02:53:26.170
374,760
374,760
[ "html", "css" ]
3,747,942
1
3,748,045
null
0
275
I was looking at ER diagrams today. If we consider two entities, Item and Member in the context of a rental shop, the member can either checkout an item or renew the item. So for this, I came up with the following: ![alt text](https://i.stack.imgur.com/EAWuI.jpg) The idea was that a member can check out any number of items but an item can be checked out only once. And, a member can renew any number of items and an item can be renewed by only one member. But my problem is that once a member renews an item, do I need to explicitly indicate it in the ER diagram somehow? I mean, lets say I renew an item, how do I indicate that it should be updated in the `CHECKOUT_LOG` table or is it specific only to the relational model?
Do I need to model a dependency explicitly in an ER diagram?
CC BY-SA 2.5
null
2010-09-19T23:48:25.617
2010-09-20T00:30:05.343
null
null
184,046
[ "sql", "database", "database-design", "entity-relationship" ]
3,748,037
1
3,820,976
null
8
5,708
I'm on the [FIRST](http://www.usfirst.org/) robotics team at my high school, and we are working on developing a kiwi drive robot, where there are three [omni wheels](http://en.wikipedia.org/wiki/Omni_wheel) mounted in a equilateral triangle configuration, like this: ![three numbered omni wheels in an equilateral triangle configuration](https://i.stack.imgur.com/x6u31.png) The problem is programming the robot to drive the motors such that that the robot moves in the direction of a given joystick input. For example, to move "up", motors 1 and 2 would be powered equally, while motor 3 would be off. The joystick position is given as a vector, and I was thinking that if the motors were expressed as vectors too, [vector projection](http://en.wikipedia.org/wiki/Vector_projection) might be what I need. However, I'm not sure if this is right, and if it is, how I would apply it. I also have a feeling that there may be multiple solutions to one joystick position. Any help would be greatly appreciated.
How to control a kiwi drive robot?
CC BY-SA 2.5
0
2010-09-20T00:26:25.493
2011-04-20T04:30:24.257
null
null
137,746
[ "language-agnostic", "math", "vector", "robotics" ]
3,748,082
1
3,748,093
null
0
1,027
I have a table that keeps the user ratings for items. I want to allow each user to rate an item only once, is there any way to force the database not to allow duplicate for itemId and userId? ![alt text](https://i.stack.imgur.com/1fw0n.png) I don't want each individual field to be a primary key. I want the primary key to be based on both of them at the same time. for example there is a row: ``` itemId= 1 & userId = 1 ``` following should be allowed: ``` itemId= 2 & userId = 1 itemId= 1 & userId = 2 ``` following should NOT be allowed: ``` itemId= 1 & userId = 1 ```
Relational Database Design - double primary key in one table?
CC BY-SA 2.5
null
2010-09-20T00:48:55.307
2010-09-20T04:59:03.310
2010-09-20T04:59:03.310
13,302
242,769
[ "mysql", "database-design", "primary-key" ]
3,748,252
1
3,748,629
null
9
10,676
I'm running this code: ``` $db = new Mongo("mongodb://user:[email protected]:27081/dbname"); $collection = $db->foobar; $collection->insert($content); ``` I'm trying to test mongohq by just creating a random collection. I'm getting this error: ``` Fatal error: Call to undefined method MongoDB::insert() in /ajax/db.php on line 24 ``` I have the client installed as far as I know: ![alt text](https://i.stack.imgur.com/FsMwB.jpg) I'm also running php 5.2.6 What's the problem? Thanks.
php mongodb : Call to undefined method MongoDB::insert() in db.php
CC BY-SA 2.5
null
2010-09-20T01:45:38.687
2010-09-20T04:00:22.737
2010-09-20T03:34:05.397
378,226
378,226
[ "php", "mongodb", "mongodb-php" ]
3,748,461
1
null
null
0
204
I have a database table with records and I show them on a view page, as below. ![alt text](https://i.stack.imgur.com/NImGz.png) --- my question is: If I click "Destroy" Button the corresponding "quote" should not be deleted from Database but it should be removed from view page for my browser only (using cookies?) (not affected for other computers). How can I implement this ? Thank you. Destroy view is as below: ``` <%= link_to "Destroy",quotation_path(p),:method=>:delete %> ``` and controller: ``` def destroy @quotation = Quotation.find(params[:id]) @quotation.destroy respond_to do |format| format.html { redirect_to(quotations_url) } format.xml { head :ok } end end ```
Remove String from View as save as Cookie
CC BY-SA 2.5
null
2010-09-20T03:03:05.383
2010-09-20T20:37:40.267
null
null
349,710
[ "ruby-on-rails", "ruby-on-rails-3" ]
3,748,729
1
3,748,969
null
3
831
I'm trying to do like what you can see on the image below: ![alt text](https://i.stack.imgur.com/yyaiZ.png) I'm using Microsoft Visual Studio 2008. In my Form I added a `TabControl` and set its `Alignment` properties to `Bottom`. But as you can see in the image below, It seems there's something wrong in the display. How can I fix it? ![alt text](https://i.stack.imgur.com/oLPhH.png)
Setting TabControl Alignment Properties. C# Winforms
CC BY-SA 2.5
null
2010-09-20T04:36:48.293
2010-09-20T05:55:02.367
null
null
396,335
[ "c#", "winforms" ]
3,748,978
1
3,749,132
null
1
1,493
I want to use a [SlidingDrawer](http://developer.android.com/reference/android/widget/SlidingDrawer.html) in an activity, and I would love to just use the built-in tray handle, rather than try to find or create my own. I [found it online](http://github.com/commonsguy/cw-android/blob/master/Fancy/DrawerDemo/res/drawable/tray_handle_normal.png) thanks to CommonsWare but I assume that got it from the Android platform itself, so I figure it will benefit me in the long run to know where to find it, rather than just use their copy of it. I looked for it in my Android SDK installation, under `platforms/android-8/android.jar/res/` but with no success. ![SlidingDrawer handle](https://i.stack.imgur.com/wtTB0.png) Where can I find the above image, in the Android SDK itself, rather than just downloading it?
Where is the drawable for the handle of a SlidingDrawer defined?
CC BY-SA 2.5
0
2010-09-20T05:57:51.920
2010-09-20T07:50:17.860
null
null
65,977
[ "android", "resources", "drawable" ]
3,749,265
1
3,749,285
null
0
958
I have a static web method which returns an object and this object has some values. I am calling this function from an ajax call. ``` $.ajax({ url: "EuclidAktarim.aspx/f_EuclideGonder_", type: "POST", data: "{_sTCKimlikNo:'" + tc + "', _iKlinik_id:" + iKlinikId + ", _iYil:" + iYil + ", _byAy:" + seciliAy + ", _iUid:" + iUid + ", _bHepsi:" + $(cbHepsi).attr("checked") + ", _sServisAdresi:'" + sEuclidServisAdres + "', _enumKanTahlilikontrolTarih:'" + sCalismaKayitTarihi + "', _enumHastaKontrolKodu:'" + sHastaKontrolKodu + "', _bSimuleEt:" + simuleEt + "}", contentType: "application/json; charset=utf-8", beforeSend: function(xhr) { $(spn).html("<img src='Img/loadingSatir.gif' alt='Gönderiliyor'/>"); }, success: function(msg) { var sonuc = ""; sonuc = msg.hasOwnProperty('d') ? msg.d : msg; $(spn).html("<img src='Img/green-check.gif' alt='" + sonuc + "'/>"); }, error: function(hata) { var sonuc = ""; sonuc = hata.hasOwnProperty('d') ? hata.d : msg; $(spn).html("<img src='Img/error.gif' alt='" + sonuc + "'/>"); }, complete: function(eee) { if ($(spn).html() == "<img src='Img/loadingSatir.gif' alt='Gönderiliyor'/>") { $(spn).html("Göndermek için tekrar tıklayınız.") } } }); ``` I can see this result while looking to a watch for "msg:d" in success part. ![alt text](https://i.stack.imgur.com/kRrf4.png) I want to read M_Durum object but it says msg.d.M_Durum is undefined object. Where is the problem i dont understand. Thanks for your helps. KR,
Reading json return value
CC BY-SA 2.5
null
2010-09-20T07:04:11.513
2010-09-20T07:07:01.963
null
null
117,899
[ "jquery", "json", "asp.net-ajax" ]
3,749,304
1
null
null
1
971
When you insert a flash object into the CKeditor the editor window will show this symbol: ![alt text](https://i.stack.imgur.com/xmavH.png) I was wondering. Is it possible to do something similar when users inserts this tag into the editor (using regex {formbuilder=(\d+)}/ ): {formbuilder=2} If so, could someone please explain how to? :) I've been looking at the PageBreak plugin to try and understand what the hell is going on. The big difference between this plugin and mine is the way the HTML is inserted into the editor. ``` CKEDITOR.plugins.add('formbuilder', { init: function(editor) { var pluginName = 'formbuilder'; var windowObjectReference = null; editor.ui.addButton('Formbuilder', { label : editor.lang.common.form, command: pluginName, icon: 'http://' + top.location.host + '/publish/ckeditor/images/formbuilder.png', click: function (editor) { if (windowObjectReference == null || windowObjectReference.closed){ var siteid = $('#siteid').val(); windowObjectReference = window.open('/publish/formbuilder/index.php?siteid='+siteid,'Formbuilder','scrollbars=0,width=974,height=650'); } else { windowObjectReference.focus(); } } }); } }); ``` As you can see, my plugin opens a new window and the tag is inserted with: ``` function InsertForm(form_id) { // Get the editor instance that we want to interact with. var oEditor = CKEDITOR.instances.page_content; // Check the active editing mode. if ( oEditor.mode == 'wysiwyg' ) { // Insert the desired HTML. oEditor.insertHtml( '{formbuilder='+form_id+'}' ); } else alert( 'You must be on WYSIWYG mode!' ); } ``` The PageBreak plugin does everything when you click on the toolbar icon. This makes it possible to make the fakeImage inside the plugin file. For me on ther other hand, I don't see how this is possible :\
CKeditor - Custom tags and symbols inside the editorwindow
CC BY-SA 2.5
0
2010-09-20T07:09:30.743
2011-01-26T22:35:45.057
2010-09-21T17:57:47.700
286,295
286,295
[ "regex", "tags", "ckeditor", "placeholder" ]
3,749,329
1
3,749,410
null
1
27,917
I am having trouble displaying results from a SQL query. I am trying to display all images and prices from a products table. I am able to display the echo statement "Query works" in the browser. But, the results are not displaying in the browser. ``` if ($count > 0) { echo "Query works"; } else { echo "Query doesn't work" ."<br/>"; } ``` ``` $con = getConnection(); $sqlQuery = "SELECT * from Products"; // Execute Query ----------------------------- $result = mysqli_query($con, $sqlQuery); if(!$result) { echo "Cannot do query" . "<br/>"; exit; } $row = mysqli_fetch_row($result); $count = $row[0]; if ($count > 0) { echo "Query works"; } else { echo "Query doesn't work" ."<br/>"; } // Display Results ----------------------------- $num_results = $result->numRows(); for ($i=0; $i<$num_results; $i++) { $row = $result->fetchRow(MDB2_FETCH_ASSOC); echo '<img src="'.$row['Image'].'>'; echo "<br/>" . "Price: " . stripslashes($row['Price']); ``` } ![alt text](https://i.stack.imgur.com/3qbi6.png) ![alt text](https://i.stack.imgur.com/gyoYf.png) ![alt text](https://i.stack.imgur.com/JvFrx.png)
Display SQL query results
CC BY-SA 2.5
0
2010-09-20T07:13:10.967
2013-02-23T20:02:48.997
2010-09-20T08:38:51.547
422,157
422,157
[ "php", "sql" ]
3,749,413
1
null
null
0
301
i have a properties folder and inside of ti contains my jdbc.properties file. the problem is that i am unable to load it succesfuly as it always complains that it cannot locate the file. i have the file currently sitting in the roo directopry fo WEB-INF. when i build and compile my spring mvc it does throw any exceptions but as soon as i load the beans from my code using new ClassPathXmlApplicationContext it fails and says it cannot locate my properties file?? here is how my beans look like: ``` <bean id="propertyConfigurer" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"> <property name="locations"> <list> <value>/properties/jdbc.properties</value> </list> </property> </bean> <bean id="dataSource1" class="org.springframework.jdbc.datasource.DriverManagerDataSource"> <property name="driverClassName" value="${database.driver}" /> <property name="url" value="${database.url}" /> <property name="username" value="${database.user}" /> <property name="password" value="${database.password}" /> </bean> ``` here is a pic of my project structure at present: ![alt text](https://i.stack.imgur.com/0isig.jpg)
Best place to put my .poperties files for use with springs PropertyPlaceholderConfigurer?
CC BY-SA 2.5
null
2010-09-20T07:31:19.467
2011-06-23T21:56:38.250
null
null
444,668
[ "spring-mvc" ]
3,749,438
1
3,802,185
null
0
285
I have a concern about the separate line under navigation bar. Please take a look at below screenshot ![alt text](https://i.stack.imgur.com/KIJsh.png) At the "Overview Settings" screen, I implement UITableViewController, and I see the separate line appear natively. But at "Overview" screen, I implement UIViewController and this line is not appear. How do I make it appear on every screen without add a customized view to fake this line? Thanks so much!
Why there is no separate line under Navigation bar?
CC BY-SA 2.5
null
2010-09-20T07:35:37.763
2010-09-27T08:33:18.530
null
null
374,885
[ "iphone", "uinavigationbar" ]
3,749,650
1
3,749,922
null
3
5,833
I'm trying to create a menu, in which the last menu item (with different class) will stick automatically to the right corner of the menu. I'm attaching a screenshot for this. There are a few menu items on the left and the last item should somehow count the rest of the available space on the right in the menu div, add this space as padding to the right and display a background in whole area ON HOVER (see the screen to understand this please) ![alt text](https://i.stack.imgur.com/jWTT3.png) Is something like this possible? Thanks a lot
How to stick the last menu item automatically to the right corner?
CC BY-SA 2.5
0
2010-09-20T08:14:40.483
2010-09-20T11:12:19.533
2010-09-20T08:43:24.523
342,855
342,855
[ "css" ]
3,750,274
1
null
null
3
28,718
Is there any way to prevent the "The application's digital signature cannot be verified" warning message from appearing when you run a Java application from the command line? I'm looking for a that would allow to start an application like this on a continuous integration server, so I need a solution that would not require manual intervention. Also, I would prefer not to disable this warning for application because this could be a security risk. Not sure if helps but I do know the values of "name", "publisher" and "from" fields of the signature. ![screenshot of java digital signature warning](https://i.stack.imgur.com/Wb41A.png) Just be sure, I'm not asking about how to sign this application. # update 1 I suppose that the solution is to use `keytool` to import the certificate from the command line but for some reason it does fail to import it properly because it does not appear in control panel applet after this and the application still requires it. `keytool -importcert -file my.cer -alias alf2 -storepass changeme -noprompt` `keystore` # update 2 After lot of research on the net I made some progress, worked at least on `Windows 7` with `Java 6`: `keytool -importcert -file my.cer -keystore "%USERPROFILE%\AppData\LocalLow\Sun\Java\Deployment\security\trusted.certs" -storepass "" -noprompt -v` I looks that Sun failed to specify in the documentation the real location of the default keystore and the fact that the default password is blank. But this is not the end, because when this run on the automation user account it failed, it failed because this user did not had an keystore yet and because the command line tool `keytool` is not able to create a keystore with an empty password, requesting at least 6 characters. [see Sun's forum tread...](http://forums.sun.com/thread.jspa?threadID=5289660)
Can I prevent digital signature warning when I start a java application from command line?
CC BY-SA 2.5
0
2010-09-20T09:49:42.523
2012-02-15T13:27:40.030
2010-09-20T16:34:42.247
99,834
99,834
[ "java", "windows", "keystore", "keytool", "security-warning" ]
3,751,428
1
null
null
3
21,468
i have a problem in jw player. i set my player height = 225 width = 400. It is exact 16:9 ratio. If i play any 400x225 resolution video or exact 16:9 ratio video. i get vertical bars at both sides of the player about 5mm each. For ref image is given below. how to overcome this problem. Thanks in advance. ![alt text](https://i.stack.imgur.com/4GRPd.jpg)
jw player size is not appropriate to video resolution
CC BY-SA 2.5
0
2010-09-20T12:22:14.663
2013-12-30T12:54:24.593
null
null
445,518
[ "jwplayer" ]
3,751,858
1
3,752,291
null
1
1,377
I'm getting this error when I deploy a VB.NET application and for the life of me I cannot figure out why. I do not get this error when I run the app from the IDE and the test machine I am deploying it to has a similar configuration to the dev machine...Windows 7 & .NET 3.51 SP1 and 4.0. The app bombs out when the main form is loaded after logging in. I've narrowed it down to the main form because if I load another form from login and then open the main form, this happens. Linked below is a screenshot of the stack trace. Any ideas? I'm really lost here. Thanks. ![alt text](https://i.stack.imgur.com/PlQA7.jpg)
"Collection was modified; enumeration operation may not execute" error on deployment
CC BY-SA 2.5
null
2010-09-20T13:22:30.127
2010-09-20T14:14:13.180
null
null
74,238
[ "vb.net" ]
3,751,990
1
3,752,517
null
40
77,295
I've seen the following thread which is related to my question: [WPF ComboBox: background color when disabled](https://stackoverflow.com/questions/2388833/wpf-combobox-background-color-when-disabled) The above deals with changing the Content Template for a `ComboBox`. I am working with WPF, am somewhat new to Styles and Templates, and I want to change the dull gray background color of a disabled `TextBox` to some other color. We use `TextBoxes` frequently in our application and we find the default color settings difficult to read. I've crafted the following solution attempt. But of course, it does not work. Can someone give me an opinion on why? ![Upload Image](https://i.stack.imgur.com/QBOxY.png)
How to change disabled background color of TextBox in WPF
CC BY-SA 3.0
0
2010-09-20T13:38:02.697
2016-05-24T06:29:43.460
2017-05-23T11:47:00.513
-1
452,763
[ "wpf", "templates", "textbox", "background", "controls" ]
3,752,015
1
3,752,039
null
1
1,037
Is it possible to customize a tree widget so that the full row will be selected and also move the items a little to the left so that there will not be that much white space? I would like it to get it looking like this: ![alt text](https://i.stack.imgur.com/1gdjh.png) Instead of the default look that is this: ![alt text](https://i.stack.imgur.com/C7ZNe.png)
Customize a Qt Tree Widget
CC BY-SA 2.5
null
2010-09-20T13:41:00.583
2010-09-20T13:44:18.560
null
null
9,789
[ "qt4" ]
3,752,476
1
3,753,428
null
43
63,507
I have already taken a look at this question: [SO question](https://stackoverflow.com/questions/1616767/pil-best-way-to-replace-color) and seem to have implemented a very similar technique for replacing a single color including the alpha values: ``` c = Image.open(f) c = c.convert("RGBA") w, h = c.size cnt = 0 for px in c.getdata(): c.putpixel((int(cnt % w), int(cnt / w)), (255, 0, 0, px[3])) cnt += 1 ``` However, this is very slow. I found [this recipe](http://mail.python.org/pipermail/image-sig/2002-December/002092.html) out on the interwebs, but have not had success using it thus far. What I am trying to do is take various PNG images that consist of a single color, white. Each pixel is 100% white with various alpha values, including alpha = 0. What I want to do is basically colorize the image with a new set color, for instance #ff0000<00-ff>. SO my starting and resulting images would look like this where the left side is my starting image and the right is my ending image (NOTE: background has been changed to a light gray so you can see it since it is actually transparent and you wouldn't be able to see the dots on the left.) ![alt text](https://i.stack.imgur.com/aVyKO.png) Any better way to do this?
Python: PIL replace a single RGBA color
CC BY-SA 4.0
0
2010-09-20T14:37:19.750
2019-03-17T16:04:43.187
2019-03-17T16:04:43.187
1,371,141
141,555
[ "python", "colors", "python-imaging-library" ]
3,752,575
1
null
null
-2
143
![alt text](https://i.stack.imgur.com/lGvxY.jpg) ![alt text](https://i.stack.imgur.com/FBVRn.jpg) ![alt text](https://i.stack.imgur.com/NNF31.jpg) From the above graphs I know there are `9` sections,but why in the 1st graph it shows `0900`? How to read numbers in PE format?
Understanding numbers in PE
CC BY-SA 2.5
null
2010-09-20T14:49:05.847
2011-02-27T02:28:22.267
2020-06-20T09:12:55.060
-1
444,905
[ "portable-executable" ]
3,752,758
1
null
null
0
957
In Eclipse Ganymede (3.4), you could navigate to: > Window > Preferences > Validation ... and enable/disable various Validators. This feature seems to have disappeared in 3.5. I can't find any documentation pointing me to a new location. This is what I'm expecting: ![Eclipse Validator Preferences](https://i.stack.imgur.com/zypj1.jpg) This is what my Preferences window looks like: ![alt text](https://i.stack.imgur.com/zwJjg.png) I'm looking to disable several Validators, but the Seam Validator is my highest priority.
Configure Code Validation in Eclipse Galileo (3.5)?
CC BY-SA 2.5
null
2010-09-20T15:09:06.133
2010-09-21T18:17:12.777
2010-09-20T18:33:31.633
176,741
176,741
[ "java", "eclipse", "syntax-checking" ]
3,753,055
1
3,753,121
null
7
26,262
![alt text](https://i.stack.imgur.com/BvgT0.gif) How to display 192 character symbol in perl ?
How can I display Extended ASCII Codes characters in Perl?
CC BY-SA 2.5
0
2010-09-20T15:40:17.197
2021-11-28T21:53:15.020
2010-09-20T16:47:57.133
2,766,176
352,860
[ "perl", "ascii", "extended-ascii" ]
3,753,098
1
3,777,002
null
2
358
I have a desktop application written in Ruby that is using GTK2. It's just a small test application to play with GTK2, but I'm having problems achieving what I want to do. Is there any way using GTK2 to get at the titlebar (apart from setting the title), specifically to either add a button to it (beside the min/max/etc, B in the below diagram) or to add an option to the menu that pops up when you click the icon on the titlebar (A in the below diagram)? ![alt text](https://i.stack.imgur.com/c29uo.png) I'm thinking there might not be because GTK is meant to work with many many different window managers, but I just wondered if there was. As a side question, what event does clicking the 'cross' button fire? At the moment if the user clicks that the window disappears but the program doesn't end - I need to capture that event and quit the program. Thanks for any help, including hitting me over the head and telling me how silly I am.
Is there a way to make changes to the titlebar with GTK2?
CC BY-SA 2.5
null
2010-09-20T15:44:45.993
2014-03-13T06:51:39.160
null
null
352,636
[ "ruby", "titlebar", "gtk2" ]
3,753,206
1
3,758,488
null
0
503
What I am trying is the following: 1. I got an MVC app. running DIRECTLY in "Default Web Site"... 2. I got another app. ( ProductionService ) which is another standalone app.. Looks like this in IIS-Manager: ![alt text](https://i.stack.imgur.com/Ct94r.png) My problem is, that a requets to "ProductionService" is not routed to the app., but instead is handled by the MVC-app. running under "Default Web Site" I tried the MVC IngoreRoute method, but it didn't change the result.. here is my last "RegisterRoutes" with all my try & errors ;) ``` routes.IgnoreRoute("Staging/{*pathInfo}"); routes.IgnoreRoute("ProductionService/{*pathInfo}"); routes.IgnoreRoute("StagingService/{*pathInfo}"); routes.IgnoreRoute("/Staging/{*pathInfo}"); routes.IgnoreRoute("/ProductionService/{*pathInfo}"); routes.IgnoreRoute("/StagingService/{*pathInfo}"); routes.IgnoreRoute("~/Staging/{*pathInfo}"); routes.IgnoreRoute("~/ProductionService/{*pathInfo}"); routes.IgnoreRoute("~/StagingService/{*pathInfo}"); routes.IgnoreRoute("~/Staging/{*pathInfo}"); routes.IgnoreRoute("~/ProductionService/{*pathInfo}"); routes.IgnoreRoute("{*Staging*}"); routes.IgnoreRoute("{*ProductionService*}"); routes.IgnoreRoute("{*StagingService*}"); ``` So, any ideas what I can do? Maybe configure sth. in IIS directly?
Multiple ASP.net MVC2 applications on IIS7 ( hosting an MVC app. in another MVC app. )
CC BY-SA 3.0
null
2010-09-20T15:57:35.150
2014-05-23T09:04:16.063
2014-05-23T09:04:16.063
759,866
109,321
[ "asp.net-mvc", "iis", "asp.net-mvc-2", "iis-7", "asp.net-mvc-routing" ]
3,753,308
1
4,081,258
null
1
692
My dropdownlist width is smaller than the longest text in the SelectList. When I click the dropdown, it resizes to fit properly. If I remove the .accordion from the div, the dropdowns all size correctly when the page loads. How can I get it to size properly? This is how I set the accordion. ``` $("#acc").accordion({ autoHeight: false, navigation: true }); ``` One of my dropdowns: ``` <%= Html.LabelFor(x => x.Contract.contract_type) %> <%= Html.DropDownListFor(x => x.Contract.contract_type, new SelectList(Model.Lookups.nfoContractTypes, "id", "contract_type", Model.Contract.contract_type), new { @class = "edittext" })%> ``` In my .css: ``` fieldset .edittext { float:right; } ``` Without accordion: ![alt text](https://i.stack.imgur.com/3J93w.jpg) With accordion: ![alt text](https://i.stack.imgur.com/XYFHE.jpg) After clicking: ![alt text](https://i.stack.imgur.com/yKd3T.jpg) Just discovered, it is properly sized in Firefox, but not in IE8.
DropDownList not autosized properly within Jquery UI Accordion
CC BY-SA 2.5
null
2010-09-20T16:08:40.207
2010-11-02T19:11:15.347
2010-09-21T15:03:16.623
239,793
239,793
[ "jquery", "drop-down-menu", "accordion", "jquery-ui-accordion", "html.dropdownlistfor" ]
3,753,511
1
3,754,188
null
1
2,093
![alt text](https://i.stack.imgur.com/pKWR9.png) CSS: ``` select { float:left; background:url(../images/bg_search_sml.png) top left repeat-x; border:none; width:200px; font:15px Arial, Helvetica, sans-serif; letter-spacing:-1px; padding:7px 0 10px; } option { height:auto; outline:none; border:none; } ``` Why only opera and IE6 has problems with this tag. What i must do in opera and IE6 that tag will work like in IE7,8 or FF. Code forr CSS is up. regards
CSS opera problem with <select> tag
CC BY-SA 2.5
null
2010-09-20T16:38:46.073
2010-09-20T18:13:08.600
null
null
267,679
[ "html", "css" ]
3,753,696
1
3,754,155
null
0
1,133
I am trying to combine bold and regular text in a textfield but how do I embed an font family and not just a single style of a font? See example of how I embedded a font, you can only choose one style: "regular", "bold", "italic" or "bold italic" at once: ![alt text](https://i.stack.imgur.com/oekAf.png) However, when you try to embed the text (via the IDE settings or actionscript) how do you set the font to be the entire family? ![alt text](https://i.stack.imgur.com/D40Mw.png) See: family only allows "ArialRegular" and not "Arial", the entire family?
Flash CS5: combining bold and regular text in a textfield?
CC BY-SA 2.5
null
2010-09-20T17:04:20.137
2010-09-21T12:27:09.160
null
null
147,915
[ "flash", "actionscript-3", "fonts", "flash-cs5" ]
3,753,743
1
3,753,868
null
0
577
I have created a web application and site collection on a sharepoint server 2010 which is installed on remote server (Windows Server 2008). Everything is working, except that, when I try to create workflow for this site at Visual Studio 2010, it throws the following exception: ![alt text](https://i.stack.imgur.com/EA4IK.png)
sharepoint connection error
CC BY-SA 2.5
null
2010-09-20T17:11:36.897
2010-09-20T17:29:10.247
2010-09-20T17:16:47.480
199,122
388,444
[ "visual-studio-2010", "sharepoint-2010" ]
3,753,843
1
3,754,781
null
0
2,171
![alt text](https://i.stack.imgur.com/0d072.png)After struggling all weekend, I finally have a sphere reflecting its environment in OpenGL. It almost looks good. Problem is, certain features don't line up. I can't find much information on the topic of OpenGL sphere mapping, outside of a two page section in the Red Book and a few scattered, and mostly unfinished forum topics. Not sure it's necessary, but I included my code where I load the textures. After trial and error, I found that having symmetrical dimensions freom 0 to 512 gets the best results, but they still aren't perfect (and the dimensions have to be powers of two, or it crashes). Does any one know of any strategies to get textures that line up more correctly? ``` void loadCubemapTextures(){ glGenTextures(1, &cubemap); glBindTexture(GL_TEXTURE_CUBE_MAP, cubemap); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_R, GL_REPEAT); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR); glDrawBuffer(GL_AUX1); glReadBuffer(GL_AUX1); glMatrixMode(GL_MODELVIEW); //Generate cube map textures for(int i = 0; i < 6; i++){ glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); glLoadIdentity(); //Viewing Transformation gluLookAt(pos[0], pos[1], pos[2], view_pos[i][0], view_pos[i][1], view_pos[i][2], top[i][0], top[i][1], top[i][2]); glMatrixMode(GL_PROJECTION); glLoadIdentity(); gluPerspective(90.0, 1.0, cubemapRadius + 1, 200.0); glMatrixMode(GL_MODELVIEW); render(); glCopyTexImage2D(GL_TEXTURE_CUBE_MAP_POSITIVE_X + i, 0, GL_RGB, 0, 0, 256, 256, 0); } ```
OpenGL CubeMap Texture Dimensions
CC BY-SA 2.5
null
2010-09-20T17:25:09.487
2010-09-21T15:12:22.723
2010-09-20T18:35:57.947
364,015
364,015
[ "opengl", "rendering", "textures" ]
3,754,057
1
3,754,761
null
5
3,643
I am having an issue where the background color is behaving unexpectedly when the viewport is shrunk to a size smaller than that specified for some of my elements. While the scroll bars appear correctly the background is not what I would expect. When the viewport is as large or larger the backgrounds behave as intended. When inspecting the page elements with Firebug it seems that the `body` element is not stretching even though content inside of it is. What's causing the backgrounds to behave this way? I've provided what I believe to be the pertinent html and CSS, but if I've omitted something please let me know. ![Broken Example](https://i.stack.imgur.com/HCnXL.png) ![Working Example](https://i.stack.imgur.com/NigbB.png) ``` html { background: #A37C45; } body { background: #55688A url("../images/backgrounds/ns_bg.gif") repeat-x scroll 0 0; } #container { width: 100%; } #header { width: 730px; margin-left: auto; margin-right: auto; padding: 5px; overflow: hidden; } #main { width: 730px; margin-top: 2px; margin-left: auto; margin-right: auto; overflow: hidden; } #footer { background: url("../images/backgrounds/grass.png") repeat-x scroll left top; clear: both; width: 100%; overflow: hidden; padding-top: 30px; margin-top: 20px; } #footercontainer { width: 100%; background-color: #A37C45; margin-top: -1px; } #footercontent { width: 730px; margin-left: auto; margin-right: auto; padding-bottom: 25px; overflow: hidden; } ``` ``` <html> <body> <div id="container"> <div id="header"> </div> <div id="main"> </div> </div> <div id="footer"> <div id="footercontainer"> <div id="footercontent"> </div> </div> </div> </body> </html> ```
Viewport width causing background to not show as expected
CC BY-SA 2.5
0
2010-09-20T17:55:27.077
2011-05-31T15:49:20.693
null
null
61,654
[ "css", "html", "viewport" ]
3,754,469
1
3,755,460
null
8
14,606
How to fix `display:inline-block;` on IE6 ? My html Page [http://www.faressoft.org/tutorialTools/slideShow/](http://www.faressoft.org/tutorialTools/slideShow/) ![alt text](https://i.stack.imgur.com/KxNxB.gif)
How to fix display:inline-block on IE6?
CC BY-SA 2.5
0
2010-09-20T18:46:44.650
2010-09-20T21:08:35.730
2010-09-20T18:54:09.767
423,903
423,903
[ "html", "css", "internet-explorer", "internet-explorer-6" ]
3,754,813
1
3,755,106
null
2
475
Im using firebug to debug jquery and in the dom tab i can see all the vars and arrays in there. How do I access the different arrays and vars in the dom? Cheers Ke![alt text](https://i.stack.imgur.com/mzDlB.jpg) I cannot access these object items, even though firefox lists them, i have sitems in the top level of the dom, i also have sitems within the parent variable. a lot of head scratching happening here, would be grateful for any help :)
jquery - how do i access those arrays and variables in the dom?
CC BY-SA 2.5
null
2010-09-20T19:28:24.487
2010-09-21T21:49:59.610
2010-09-21T19:37:03.477
264,975
264,975
[ "javascript", "jquery", "firebug" ]
3,754,824
1
3,757,135
null
0
161
I'm trying to add Aptana to my Eclipse installation. I'm trying to do so on Win7 x64. I've tried both x86 and x64 versions of Eclipse. Most of the time Eclipse would install just fine, run okay, but as soon as I try to pluin Aptana it has problems. It will start up, then encounter an error immediately and close. Right now I have the x64 version installed fine. When I start it up it throws the error but doesn't close. I can close the error window and continue using Aptana just fine. I've attached a couple screenshots to show what the error is and what my current Installation Details look like. Let me know if there's any other information I could provide. Thanks in advance. Aaron- ![alt text](https://i.stack.imgur.com/e6B19.png) ![alt text](https://i.stack.imgur.com/244kg.png)
Trouble plugging Aptana into Eclipse
CC BY-SA 3.0
0
2010-09-20T19:30:08.923
2015-04-17T00:09:28.367
2015-04-17T00:09:28.367
122,012
376,386
[ "eclipse", "eclipse-plugin", "aptana" ]
3,754,964
1
3,755,114
null
5
12,026
While converting a desktop application to a web app, I've run across my ignorance when attempting to implement a multi-column data entry form using CSS. I'm resolved to avoid using tables for this type of thing, and while I found a good [reference](http://articles.sitepoint.com/article/fancy-form-design-css) to laying out a data entry form, I can find nothing that applies to multiple-column layouts like this one: ![enter image description here](https://i.stack.imgur.com/HTfsA.png) Can anyone point me in the right direction?
How to create multi-column data entry form using CSS in Asp.Net?
CC BY-SA 3.0
0
2010-09-20T19:50:59.807
2013-05-03T20:09:41.237
2013-05-03T20:09:41.237
23,199
357,859
[ "asp.net", "css", "forms", "data-entry" ]
3,755,200
1
3,790,298
null
1
4,551
I have a XSD in local , and I need to import the same into a WSDL. I have couple of other xsds too which are already on the production namespace. Now I have little clue as how to make this XSD that is only in my local to be made available in my WSDL file to test the webservice using soapUI. So questions, what will be the namespace and how will i provide the schemalocation. (I am a newbie to wsdl Namspaces, so plz dont mind this basic question. Googling simply does not tell me anything about the how to.) For the ones that are in Prod its like this: ![alt text](https://i.stack.imgur.com/IXIx7.jpg)
How to specify schemalocation for an xsd in local folder, while importing it into a wsdl file
CC BY-SA 2.5
0
2010-09-20T20:26:42.960
2010-09-24T19:25:38.020
2010-09-21T06:12:06.617
236,998
236,998
[ "namespaces", "xsd", "wsdl" ]
3,755,398
1
3,755,967
null
1
977
``` private static void writeData( byte[] file, HttpServletResponse response ) throws IOException { .... // Send the data response.setContentLength(file.length); response.getOutputStream().write(file); } ``` Recently, I've found in IE8 that some connections close while requesting files to download. This is the relevant piece of source in code, and I was wondering if writing large byte arrays all at once to the response output stream could cause this issue. The issue is very much non-reproducible, and I've often seen the pattern of writing a certain number of bytes at a time, versus all at once, to avoid MTU issues, or something like that. Could this code be responsible for my intermittent IE issues? If so, why, and why only in IE? I tried using `Cache-Control: no-cache`, and the results were catastrophic in IE. ![alt text](https://i.stack.imgur.com/E0aGA.png) ``` POST /myapplication/someAction.do?step=none&SAct=none HTTP/1.1 Accept: application/x-ms-application, image/jpeg, application/xaml+xml, image/gif, image/pjpeg, application/x-ms-xbap, application/x-shockwave-flash, */* Referer: https://myhost.myhost.com/myapplication/someAction.do?queryString=something Accept-Language: en-US User-Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; MS-RTC LM 8; .NET4.0C; InfoPath.3) Content-Type: application/x-www-form-urlencoded Accept-Encoding: gzip, deflate Host: myhost.myhost.com Content-Length: 1644 Connection: Keep-Alive Cache-Control: no-cache Cookie: JSESSIONID=GnvHMYyGx9QrmpVQfBSgNXnPM8nQJ21dT82KhmSSTXRRT1mgB8tP!299858932; [truncated] ``` ``` HTTP/1.1 200 OK Cache-Control: no-cache Date: Tue, 21 Sep 2010 18:00:56 GMT Transfer-Encoding: chunked Content-Type: application/ZIP Content-Disposition: inline; filename=ActivityReport.ZIP X-Powered-By: Servlet/2.5 JSP/2.1 ```
Possible effects of writing large byte arrays to an output stream?
CC BY-SA 2.5
null
2010-09-20T20:52:15.740
2010-09-21T19:38:29.187
2010-09-21T18:17:00.557
78,182
78,182
[ "java", "internet-explorer-8", "streaming", "weblogic" ]
3,755,909
1
null
null
1
325
In the screen shot you see a list of items on the left (not floated) and a display box on the right (floated). How can I prevent the left item's li element from cutting into the display box. The li content follows the flow and breaks to a new line before running into the display box, but the li element, as in the container, does not. ![Left div cuts into right div](https://i.stack.imgur.com/qo15w.jpg) Li items on the left: ``` border: 1px solid #000000; display: block; margin-bottom: 8px; padding: 10px; ``` Display box on the right: ``` border: 3px double #000000; display: inline-block; float: right; margin-left: 20px; padding: 15px; width: auto; ``` Thanks, Ryan ![Adding inline-block to li element](https://i.stack.imgur.com/HAwIb.jpg) The widths are dynamic on different pages, dynamic as in different per page, but they won't change on a per page basis, except for the li elements that go beyond the display box. Just like when you float a pictures to the left and the text sits on the right of the pictures, but once the pictures ends, the text continues underneath the image all the way to the right edge of the page, that's what I want in reverse. So I want the li element to go to the left edge of the right display box, but past the box, I want to go to the edge of the page. The text itself conforms to this, but for some reason, the li element does not recognize there to be an "object" to prevent it from stopping and cutting into the display box. The reason it doesn't recognize it is because of the right floated display box, which breaks things from the normal flow, but I would think there has to be a way to either manipulate the display box to it can be recognized or manipulate the li elements so they can recognize the display box.
Left content cuts into right floated content
CC BY-SA 2.5
null
2010-09-20T22:12:06.690
2012-07-23T20:37:00.207
2012-07-23T18:47:55.433
44,390
441,784
[ "html", "css", "css-float", "overlap" ]
3,755,987
1
3,800,545
null
7
526
``` <script src="/c/Currency.js" type="text/javascript" ></script> <form id="form1" runat="server"> <asp:ScriptManager ID="ScriptManager1" runat="server" EnablePageMethods="true" > </asp:ScriptManager> <div id="Content"> <div class="nobg"> <div id="Top"> <div class="left"> <a href="index.html"><img src="/i/xyz.gif" alt="Dexia" /></a> </div> <div class="right"> <div id="tmenu"> <ul> <li class="aboutus"><a href="/aboutus/"><img src="/i/menu/about_us.gif" alt="About Us"></a></li> <li class="presscenter"><a href="/press_center/"><img src="/i/menu/press_center.gif" alt="Press Center"></a></li> <li class="financials"><a href="/financials/"><img src="/i/menu/financials.gif" alt="Financials"></a></li> <li class="xysza"><a href="/work_xyz/"><img src="/i/menu/xyz.gif" alt="Work&xyz"></a></li> <li class="sitemap"><a href="/site_map/"><img src="/i/menu/site_map.gif" alt="Site Map"></a></li> <li class="ruski"><a href="/russian/"><img src="/i/menu/try.gif" alt="rt"></a></li> <li class="search"><a href="/search/"><img src="/i/menu/search.gif" alt="Search"></a></li> <li class="mainpage"><a href="/index.html"><img src="/i/menu/main_page.gif" alt="Main Page"></a></li> </ul> </div> <div id="tm"></div> </div> <div id="tms"></div> <script type="text/javascript"> var activepage = 0 </script> <script src="/c/inc/menu.js" type="text/javascript"></script> <span id="txt_submenu"></span> <script src="/c/inc/submenu.js" type="text/javascript"></script> </div> <div id="Middle"> ``` ![alt text](https://i.stack.imgur.com/GO34G.png) Unfortunately this menu does not appear after I transform html file to aspx, what am I missing? ![alt text](https://i.stack.imgur.com/l5xZL.png) Do I missing something to enable? Since the order of index.html file is absolutely the same with index.aspx , just I want to see the js powered menu. please help! I just released that when I remove from the file, the menu appears. You may check the content of the Currency.js below.. please check-it up and let me know how can I fix this problem PS: I tried to replace the place of the reference of Currency.js to header block. But it did not work either.. ``` function CallMe() { // call server side method PageMethods.GetData(function (result) { DcSet("lblUsdRub", result.UsdRub); DcSet("lblEurRub", result.EurRub); DcSet("lblMicex", result.Micex); DcSet("lblUrals", result.Urals); DcSet("lblUsdEur", result.UsdEur); DcSet("lblUsdTur", result.UsdTur); DcSet("lblNasdaq", result.Nasdaq); DcSet("lblImkb100", result.Imkb100); }); } function DcSet(labelName, value) { document.getElementById(labelName).innerText = value.toFixed(3); } (function () { var status = true; var fetchService = function () { if (status) { CallMe(); status = false; } setTimeout(fetchService, 300000);//Every Five Minutes, Update Data status = true; } window.onload = fetchService; } ()); ``` I got the answer actually. I overwrite the onload method. Now, I need to run the Currency's necessary fetchService on load time of the method below. How can I call the window.onload = fetchService; or all function() in he main.js's below.. please help? ``` window.onload = function () { preload(); init(); externalLinks(); topmenu.Build(); if (typeof sIFR == "function") { sIFR.replaceElement(named({ sSelector: "h1", sFlashSrc: "/swf/Futura_Bk_BT.swf", sWmode: "transparent", sColor: "#027DA2", sLinkColor: "#FFFFFF", sHoverColor: "#FFFFFF", sFlashVars: "" })); } initHDS(); SubMenuKaydir(); StartCurrencyOnLoad(); } ```
Covered from html to aspx page, but the menus disappeared, why?
CC BY-SA 3.0
null
2010-09-20T22:30:50.193
2014-04-08T17:49:16.087
2014-04-08T17:49:16.087
3,447,910
173,718
[ "c#", ".net", "html", "interface", "asp.net" ]
3,756,061
1
3,934,841
null
0
560
After upgrading to IE9, InfoPath forms consistently fail on radio button selection. This occurrs even when using compatibility mode. ![IE 9 InfoPath Error Screenshot](https://i.stack.imgur.com/T5OJN.png)
IE9: radio button selection fails with Infopath forms
CC BY-SA 2.5
null
2010-09-20T22:44:07.773
2010-10-14T15:28:29.373
null
null
1,551
[ "javascript", "sharepoint", "selection", "infopath", "internet-explorer-9" ]
3,756,063
1
null
null
5
5,910
I'm trying to build a treeview like file list in a richtext box. It should look like an explorer treeview. My code is able to get an resize the icon, but the transparency is missing (light gray background instead of transparency). What do I need to change here? Is the Image format wrong? Is there a better way to add an image to a richtextbox? ``` // Get file info FileInfo f = new FileInfo("myfile.name"); // Get icon for fileinfo Icon ico = Icon.ExtractAssociatedIcon(f); // Convert icon to bitmap Bitmap bm = ico.ToBitmap(); // create new image with desired size Bitmap img = new Bitmap(16,16,PixelFormat.Frmat32bpRgb); // Create graphics with desired sized image Graphics g = Graphics.FormImage(img); // set interpolation mode g.InterpolationMode = InterpolationMode.HighQualityBiCubic; // draw/resize image g.DrawImage(bm, new Rectangle(0,0,16,16), new Rectangle(0, 0, bm.Width, bm,Height), GraphicalUnit.Pixel); // Paste to clipboard Clipboard.SetImage(bm); // Paste in RichtextBox rtb.Paste(); ``` Example: ![alt text](https://i.stack.imgur.com/viRrz.png) I've figured out that the image is transparent, but using Clipboard.SetImage() doesn't publish it as transparent image. Any ideas why and what can I do to fix it? Do I need to switch to a differn textbox control?
Icon to Image - transparency issue
CC BY-SA 2.5
0
2010-09-20T22:44:45.810
2010-10-07T22:03:17.530
2010-10-07T22:03:17.530
216,294
216,294
[ "c#", ".net", "image", "icons", "transparency" ]
3,756,069
1
3,764,110
null
0
850
Hey! I was looking at a cool layout example in particular the V3FluidLayout.xaml found inside this set of examples : [http://gallery.expression.microsoft.com/en-us/DynamicLayoutTrans](http://gallery.expression.microsoft.com/en-us/DynamicLayoutTrans) Anyhow - this appears to be a silverlight app - it runs within a browser. I am trying to pull the V3FluidLayout example into a WPF app - and struggling. I "add an existing item" pulling the .xaml file into my project. When it goes to compile it, the following errors are found : ![alt text](https://i.stack.imgur.com/opKVQ.png) Are these artifacts Silverlight? The following is the xaml code within the V3FluidLayout.xaml file [http://pastebin.com/h9ujUax6](http://pastebin.com/h9ujUax6) Can anybody help me pin why this is not working - and how I can convert that xaml code to work inside my wpf app. Thanks Andy
Expression blend convert example from Silverlight into WPF
CC BY-SA 2.5
null
2010-09-20T22:45:36.043
2010-09-22T16:16:28.147
null
null
265,683
[ "c#", "wpf", "xaml", "expression-blend" ]
3,756,367
1
null
null
0
235
I made a tab bar application with several tab bar buttons. Each button is linked to a separate xib file. This works for a xib with a UIViewController and a xib with a UITableViewController. However, it does not work for a xib with a UINavigationController. On the left you can see what it looks like in Interface Builder, and on the right is what it looks like in the simulator. ![](https://imgur.com/dnbKR.png) Why isn't it showing up correctly in the simulator?
Navigation-based app + tab bar
CC BY-SA 2.5
null
2010-09-20T23:49:14.290
2011-06-28T08:13:48.427
2010-09-21T01:23:54.547
404,020
404,020
[ "objective-c", "cocoa-touch", "xcode", "uinavigationcontroller", "uitabbar" ]
3,756,385
1
null
null
0
377
I try to send parameter from menu page to My home page which include both the menu page and the page which comes through a parameter from one href form menu page . MainPage inside folder in my web app, and all other jsps and the menue inside AdminPages folder inside the web-inf folder , so when i call AnyPage.jsp from the menu i make Add new user and in the MainPage is that for the fisrt time I press on add new user link it works properly and call it's sevlet but when i click again over it , an exception happen The requested resource (/IUG_OSQS_system_web//MainPage.jsp) is not available. i think it save parameter and make something of concatanation ! or other thing which i don't know !! Can any body help?Here is a picture which could help to get what i mean? ![alt text](https://i.stack.imgur.com/a4zFz.png)
Are the parameters sent from one jsp to another jsp page are saved?
CC BY-SA 2.5
null
2010-09-20T23:54:07.273
2010-09-21T02:27:24.067
null
null
2,067,571
[ "jsp", "parameters" ]
3,756,395
1
3,778,236
null
19
19,203
I am trying to add a custom control as the titleView in a UINavigationBar. When I do so, despite setting the frame and the properties that would normally assume full width, I get this: ![alt text](https://i.stack.imgur.com/NNgHb.png) The bright blue can be ignored as it is where I am hiding my custom control. The issue is the narrow strips of navbar at the ends of the bar. How can I get rid of these so my customview will stretch 100%? ``` CGRect frame = CGRectMake(self.view.bounds.origin.x, self.view.bounds.origin.y, self.view.width, kDefaultBarHeight); UANavBarControlView *control = [[[UANavBarControlView alloc] initWithFrame:frame] autorelease]; control.autoresizingMask = UIViewAutoresizingFlexibleWidth; self.navigationItem.titleView = control; ``` PS - I know I can add the view by itself instead of being attached to a navigation bar and it would be very easy to position it myself. I have my reasons for needing it to be "on" the navigation bar, and those reasons are [here](https://stackoverflow.com/questions/3747991/uisearchbar-animating-of-top-of-another-uiview-besides-uinavigationbar)
How can I get a full-sized UINavigationBar titleView
CC BY-SA 2.5
0
2010-09-20T23:55:50.523
2017-10-15T12:42:03.803
2017-05-23T12:17:32.580
-1
69,634
[ "iphone", "uiview", "uinavigationbar", "uinavigationitem" ]
3,756,629
1
3,757,221
null
0
140
When I open SVN working folder with Dreamweaver, it creates additional folder and files. ![alt text](https://i.stack.imgur.com/0UAWe.jpg) Do I have to commit it to the SVN or don't?
Open with DW adds folder/files to .svn folder
CC BY-SA 2.5
null
2010-09-21T01:10:30.173
2010-09-21T05:16:15.393
2010-09-21T04:46:08.337
351,564
351,564
[ "svn", "dreamweaver" ]
3,756,920
1
3,758,286
null
0
2,588
I know this is probably a simple question, but I can't seem to figure it out. First of all, I want to specify that I did look over Google and SO for half an hour or so without finding the answer to my question(yes, I am serious). Basically, I want to rotate a Vector2 around a point(which, in my case, is always the (0, 0) vector). So, I tried to make a function to do it with the parameters being the point to rotate and the angle(in degrees) to rotate by. Here's a quick drawing showing what I'm trying to achieve: ![alt text](https://i.stack.imgur.com/8RiGa.png) I want to take V1(red vector), rotate it by an angle A(blue), to obtain a new vector (V2, green). In this example I used one of the simplest case: V1 on the axis, and a 90 degree angle, but I want the function to handle more "" cases too. So here's my function: ``` public static Vector2 RotateVector2(Vector2 point, float degrees) { return Vector2.Transform(point, Matrix.CreateRotationZ(MathHelper.ToRadians(degrees))); } ``` So, what am I doing wrong? When I run the code and call this function with the (0, -1) vector and a 90 degrees angle, I get the vector (1, 4.371139E-08) ... Also, what if I want to accept a point to rotate around as a parameter too? So that the rotation doesn't always happen around (0, 0)...
What's wrong with this XNA RotateVector2 function?
CC BY-SA 2.5
null
2010-09-21T02:34:06.203
2010-09-21T09:58:03.013
null
null
395,386
[ "c#", "vector", "xna", "rotation" ]
3,756,985
1
3,757,043
null
3
6,468
I'm not sure how to describe this without an image, so attached is a quick snip from what I want to do in a batch file (Windows 7 Enterprise 32 bit) ![LAN Proxy](https://i.stack.imgur.com/RFUQf.png) In Internet Options, under the Connections tab, there's a LAN settings button (marked in red), that opens the displayed dialog from the image. I already have the address and port I want, all I want is a way to check or uncheck the marked checkbox from a batch file. I would also accept an answer for how to do it in C#. EDIT: For other people who stumble across this question, this question is just for me being a power user. If you have a product that needs to change Proxy server settings, don't assume the settings are correct, use PostMan's second registry entry to properly set the proxy first.
Altering LAN Settings from a batch file and/or C#?
CC BY-SA 2.5
0
2010-09-21T02:53:46.897
2018-03-05T15:00:40.150
2010-09-23T16:36:07.457
160,527
160,527
[ "c#", "proxy", "batch-file" ]
3,757,017
1
null
null
2
585
Apple responded to my bug report with "We believe this issue has been addressed in iOS 4.2 b1 (8C5091e). Please let us know whether or not you continue to experience this issue with the newly released software by updating this bug report." I guess this acknowledges that the issue is in their code, not mine. I'll update with results when I or someone I know can update to try this. My coworker has reproduced the issue on a different computer and iPad, so it's probably not just a quirk with my setup. This is strange. I recently noticed the Leaks instrument reporting memory leaks in my application and NEVER pointing to my code in the stack traces, just various built-in libraries. Fortunately (?) I was able to strip out nearly everything and end up with a stupidly simple project that triggers this behavior every time, at least on my machine. Just to be sure, I've started a new project and gone through these steps and encountered the same behavior. I'm using Xcode 3.2.4 and Instruments 2.7, on an iPad (non-3G) with iOS 3.2.2. - - - `-(void)loadUser``-(BOOL)application:didFinishLaunchingWithOptions:` Here's the only bit of customized code, as described above. ``` - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { // Override point for customization after application launch. [window makeKeyAndVisible]; [self loadUser]; return YES; } - (void)loadUser { NSManagedObjectContext *moc = self.managedObjectContext; NSFetchRequest *fetchRequest = [[NSFetchRequest alloc] init]; NSEntityDescription *entityDescription = [NSEntityDescription entityForName:@"User" inManagedObjectContext:moc]; [fetchRequest setEntity:entityDescription]; NSError *error; NSLog(@"counting users"); NSUInteger count = [moc countForFetchRequest:fetchRequest error:&error]; if (count == NSNotFound) { NSLog(@"error: %@", error); } else if (count == 0) { NSLog(@"creating user"); // make a user NSManagedObject *object = [[NSManagedObject alloc] initWithEntity:entityDescription insertIntoManagedObjectContext:moc]; if (![moc save:&error]) { NSLog(@"error: %@", error); } [object release]; } NSLog(@"fetching user"); NSArray *results = [moc executeFetchRequest:fetchRequest error:&error]; if (results) { NSLog(@"results: %@", results); } else { NSLog(@"error: %@", error); } [fetchRequest release]; } ``` The count and insert is there because the leaks don't occur if there's no data, and this is the easiest way I know of to "populate" it. The logs are there just for straight-up sanity check; they can be removed and the leaks still show up. This code seems completely innocuous to me. When I run it on the device with Leaks, I let it automatically check for leaks after a few seconds and it comes up with this, every time: ![alt text](https://i.stack.imgur.com/zwVNY.png) This does not occur on the simulator, but always occurs on the device. Clearly something bizarre is happening here. JavaScriptCore? Where does that come into things? Here's the stack trace for one of those: ``` 16 libSystem.B.dylib thread_assign_default 15 libSystem.B.dylib _pthread_start 14 WebCore RunWebThread(void*) 13 JavaScriptCore JSC::initializeThreading() 12 libSystem.B.dylib pthread_once 11 JavaScriptCore JSC::initializeThreadingOnce() 10 JavaScriptCore WTF::initializeThreading() 9 JavaScriptCore WTF::initializeMainThread() 8 JavaScriptCore WTF::initializeMainThreadPlatform() 7 libobjc.A.dylib objc_msgSend_uncached 6 libobjc.A.dylib _class_lookupMethodAndLoadCache 5 libobjc.A.dylib lookUpMethod 4 libobjc.A.dylib prepareForMethodLookup 3 libobjc.A.dylib _class_initialize 2 libobjc.A.dylib _fetchInitializingClassList 1 libobjc.A.dylib _objc_fetch_pthread_data 0 libobjc.A.dylib _calloc_internal ``` None of the stack traces mentions my code. I'm doing no explicit multithreading. There are no web views or anything else to do with JavaScript involved. On my machine, I consistently get this result just by following the steps above. I've deleted and reinstalled the app on the iPad. I've restarted Xcode, restarted the iPad, and restarted my computer. Same deal. My questions: Can other people reproduce the same issue? (edit: one person has, on a different computer and iPad) If not, I guess it's some strange problem with my configuration, and I'd like to know what I can do to fix it. If so, what the hell is happening? Is my code at fault? Is this not how I should be fetching objects? Is it a false positive from Leaks, or a bug in Core Data? Is there a workaround? I'd really like to be able to accurately detect leaks, and this is making it hard to do so.
Truly bizarre data reported by Leaks using CoreData on iPad
CC BY-SA 2.5
0
2010-09-21T03:04:26.367
2010-10-04T15:35:12.713
2010-09-26T20:08:16.450
115,262
115,262
[ "objective-c", "cocoa-touch", "ipad", "core-data", "ios" ]
3,757,232
1
3,757,267
null
1
598
![alt text](https://i.stack.imgur.com/pOIbo.png) You guys get what I mean. I have no idea how to do this. There are no tutorials anywhere and so far I've spent about 4 hours on this to no avail. Can anyone point me to anything useful or give me a quick run down on how I would achieve this? Cheers.
How Do I Create A Page Scroller Like In Apple's iBooks?
CC BY-SA 2.5
0
2010-09-21T04:06:30.523
2010-09-21T08:59:29.753
null
null
321,090
[ "iphone", "objective-c", "ibooks" ]
3,757,418
1
null
null
0
128
![alt text](https://i.stack.imgur.com/PqmVu.jpg) A container that contains a box centered horizontally and a line centered vertically beside the left or the right side of the box. The width of the container may change dynamically so the line should also change its width (automatically). I hope the image explains that well.
An HTML challenge
CC BY-SA 2.5
null
2010-09-21T04:56:21.293
2017-06-11T08:11:45.567
2017-06-11T08:11:45.567
4,370,109
453,478
[ "html" ]
3,757,565
1
3,758,524
null
1
1,108
how we can lessen the length of Dividing bar between two components. like in this example i want the length only of two pixel. ![alt text](https://i.stack.imgur.com/VCzNl.png)
How to decrease the width of HDividedBox divider bar length in Flex?
CC BY-SA 2.5
null
2010-09-21T05:35:53.017
2010-09-21T08:30:45.110
null
null
225,402
[ "apache-flex", "actionscript-3" ]
3,757,606
1
null
null
1
279
![alt text](https://i.stack.imgur.com/8XC53.png) what will be minimum no of table will be mapped from this entity relationship model. here M1 IS PRIMARY KEY. P1 IS PRIMARY KEY, N1 IS DESCRIMINATOR OF WEAK ENTITY SET E3. AND R1 IS A RELATION SHIP (MANY TO ONE)(FROM E1 TO E2) R2 IS A RELATION SHIP (MANY TO ONE )(FROM E3 TO E2) E1 HAS TOTAL PARTICIPATION IN R1 AND E3 HAS ALSO TOTAL PARTICIPATION. WHAT WILL BE MINIMUM NO OF TABLE (RELATION SCHEMA ) WILL BE ?
Minimum no of table generation from E-R mapping
CC BY-SA 2.5
null
2010-09-21T05:45:24.860
2013-09-02T19:12:14.853
null
null
430,803
[ "database" ]
3,758,023
1
3,758,063
null
29
27,210
How can I use this square cursor (image below) in the text `<input>` tags? ![C:\WIKIPEDIA](https://i.stack.imgur.com/lbgjU.jpg)
How to use square cursor in a HTML input field?
CC BY-SA 4.0
0
2010-09-21T07:09:32.340
2021-12-23T04:02:40.363
2021-12-23T04:02:40.363
4,294,399
244,413
[ "javascript", "html", "css", "text-cursor" ]
3,758,175
1
3,758,275
null
5
3,231
My application support to display some screen in landscape mode, and in landscape mode, I set to hide the status bar to get mode space to display data. The problem is while hiding the status bar and rotate screen, it leave a white pace at status bar position until the screen is rotated completely as below screenshot. ![alt text](https://i.stack.imgur.com/xgPY7.png) I guess that steps of operations when rotating screen are: 1. hide status bar 2. rotate screen 3. resize screen to take place of status bar. So until the screen is rotated completely, user still can see the white space, it is not good and I want to do something such as: set color for that blank space to black, or set animation to hide that blank space but unlucky! So, does anyone have solution to resolve this, please help me, thanks a lot!
hide status bar in landscape mode leave a blank space when rotating
CC BY-SA 2.5
null
2010-09-21T07:33:24.637
2010-09-21T07:49:54.690
null
null
374,885
[ "iphone", "hide", "statusbar" ]
3,758,354
1
3,758,413
null
1
396
I'm not the best in Maths, but for what I am doing now I need to calculate the angle of the vector which is shown as arrow in the picture below: ![alt text](https://i.stack.imgur.com/9k67M.png) I have a point A and a point B in a 2D plane. I need to calculate the following: -
Angle of a vector pointing from A to B
CC BY-SA 2.5
null
2010-09-21T08:02:59.927
2010-09-21T19:41:13.323
2010-09-21T19:41:13.323
49,246
251,848
[ "math", "vector", "atan2" ]
3,758,366
1
3,758,417
null
1
154
I don't have much experience in SQL so I think this is not a dumb question. I have 2 tables like this. ![alt text](https://i.stack.imgur.com/zn1jM.jpg) A .. G are the members of a hierarchy. Now my requirement is as follows. > I need to filter out the members which has status = 0 from Members table.But, If the selected set contains children which has a parent with status = 0, Ignore the child and select only the parent. As an example, in the above case the set with 0 status = {B,C,D,E,F,G} But C,D,E,F has status 0 parents. So my result should be {B,G} (i.e In database layer. I don't want to query into the data structures and then iterate. Can I write a single query for this?) I will add some more examples if the question is confusing?
SQL querying over multiple tables
CC BY-SA 2.5
0
2010-09-21T08:05:12.610
2010-09-21T14:43:20.867
2020-06-20T09:12:55.060
-1
76,465
[ "sql", "sql-server", "algorithm" ]
3,758,731
1
null
null
5
12,827
Can I change back/fore color of tabs in Visual Studio 2008? ![enter image description here](https://i.stack.imgur.com/K9U7Y.png)
Visual Studio Tab change color?
CC BY-SA 3.0
0
2010-09-21T09:01:04.073
2017-10-11T07:41:12.357
2012-08-29T23:29:30.833
419
238,089
[ "visual-studio-2008", "colors", "tabs" ]
3,758,766
1
4,955,881
null
2
2,855
I am working on Weblogic 10.3.2, JSF 1.2, Richfaces 3.3.2 and Facelets 1.1.14. I have a serious performance problem, particularly showing my home page, which contains a very complex rich:datatable. When deploying the application on my local server, a request can take over 5 seconds to complete. The home page is a ui:composition of a simple template (the problem is not in the template, the other pages are reasonably fast), but the composition itself is huge (~1000 lines). The page has two parts, the lower part is a complex datatable, where I have implemented rowspan using a combination of multiple s and the attribute. The methodology followed can be seen [in this Richfaces forum discussion](http://community.jboss.org/message/545153#545153). The upper part of the page contains a list of filters for the datatable. I do not use filters in the rich:datatable headers, because I wanted something in the following fashion. ![alt text](https://i.stack.imgur.com/q86So.jpg) If the Add button is pressed, an AJAX request takes place (a4j:commandButton) to add another Filter object to the backing collection, and then are rerendered using a4j:repeat (). The rich:datatable is rerendered when the Search button is pressed. The code of my page is at the end of the post (some fields have been renamed). Observations: Modifying [BalusC's Debug Phase Listener](http://balusc.blogspot.com/2006/09/debug-jsf-lifecycle.html), I was able to see how much each phase takes. This is the request when pressing the "Add" button, where only the filters above the datatable are rendered. ``` 2010-09-21 11:23:41,235 - Processing new Request! 2010-09-21 11:23:41,235 - before - RESTORE_VIEW 1 2010-09-21 11:23:41,235 - after - RESTORE_VIEW 1 2010-09-21 11:23:41,251 - before - APPLY_REQUEST_VALUES 2 2010-09-21 11:23:41,454 - getRowData-16: 84,026 ms Home Page Query-16: 58,178 ms 2010-09-21 11:23:42,360 - after - APPLY_REQUEST_VALUES 2 2010-09-21 11:23:42,360 - before - PROCESS_VALIDATIONS 3 2010-09-21 11:23:42,438 - getRowData-16: 0,005 ms 2010-09-21 11:23:43,126 - after - PROCESS_VALIDATIONS 3 2010-09-21 11:23:43,126 - before - UPDATE_MODEL_VALUES 4 2010-09-21 11:23:43,188 - getRowData-16: 0,005 ms 2010-09-21 11:23:43,938 - after - UPDATE_MODEL_VALUES 4 2010-09-21 11:23:43,938 - before - INVOKE_APPLICATION 5 2010-09-21 11:23:43,938 - after - INVOKE_APPLICATION 5 2010-09-21 11:23:43,954 - before - RENDER_RESPONSE 6 2010-09-21 11:23:44,282 - getRowData-16: 0,007 ms 2010-09-21 11:23:45,173 - after - RENDER_RESPONSE 6 2010-09-21 11:23:45,173 - Done with Request! ``` You can see that the Apply Request Values takes about 0.8s, the Process Validations takes about 0.8s, the Update Model takes 0.8s, the Invoke Application (where the business logic takes place) takes negligible time and finally, the Render Response takes 0.9s. When I comment out the rich:datatable and only show the filters, rendering is significantly faster: ``` 2010-09-21 11:50:52,780 - Processing new Request! 2010-09-21 11:50:52,780 - before - RESTORE_VIEW 1 2010-09-21 11:50:52,780 - after - RESTORE_VIEW 1 2010-09-21 11:50:52,780 - before - APPLY_REQUEST_VALUES 2 2010-09-21 11:50:52,858 - after - APPLY_REQUEST_VALUES 2 2010-09-21 11:50:52,858 - before - PROCESS_VALIDATIONS 3 2010-09-21 11:50:52,920 - after - PROCESS_VALIDATIONS 3 2010-09-21 11:50:52,920 - before - UPDATE_MODEL_VALUES 4 2010-09-21 11:50:52,967 - after - UPDATE_MODEL_VALUES 4 2010-09-21 11:50:52,967 - before - INVOKE_APPLICATION 5 2010-09-21 11:50:52,967 - after - INVOKE_APPLICATION 5 2010-09-21 11:50:52,983 - before - RENDER_RESPONSE 6 2010-09-21 11:50:53,186 - after - RENDER_RESPONSE 6 2010-09-21 11:50:53,186 - Done with Request! ``` The whole request only took 400ms. 1. Is this performance problem a JSF component tree issue? 2. I don't think that breaking up the page into other ui:compositions would help. I believe that this would result in an identical JSF component tree. 3. What can I do to make the page faster? The code: in PasteBin
JSF - RichFaces performance problems showing complex page
CC BY-SA 2.5
0
2010-09-21T09:06:18.333
2012-04-02T14:50:00.700
2010-09-21T14:57:11.790
125,713
125,713
[ "java", "performance", "jsf", "richfaces" ]
3,758,830
1
3,759,051
null
4
3,894
I'm looking for an affordable diagramming component for a C#/.NET (WinForms) application that will let users create diagrams like this one: ![alt text](https://i.stack.imgur.com/7HB6t.png) What would you recommend to me?
.NET Block Diagram Component
CC BY-SA 2.5
null
2010-09-21T09:14:49.253
2014-05-28T10:27:11.680
2010-09-21T09:22:01.030
204,723
63,730
[ "c#", ".net", "winforms", "diagramming" ]
3,758,987
1
3,759,583
null
6
1,623
I am started working on resume retrieval(document) component based on lucene.net engine. It works great, and it fetches the document and score it based on the > the idea behind the VSM is the more times a query term appears in a document relative to the number of times the term appears in all the documents in the collection, the more relevant that document is to the query. Lucene's Practical Scoring Function is derived from the below. ``` score(q,d)=coord(q,d)·queryNorm(q)· ∑( tf(t in d) ·idf(t)2 · t.getBoost() · norm(t,d) ) t in q ``` in this - - This is very great indeed in most of the situation, but due to the fieldnorm calculation the result is not accurate Due to this we didn't get the accurate results. Say for an example i got 10000 documents in which 3000 documents got java and oracle keyword. And the no of times it appears vary on each document. - - Due to the nature of the business we need to retrieve the documents got more search keyword occurrence should come first, we don't really care about the length of the document. Because of this a Guy with a big resume with lot of keywords is been moved below in the result and some small resumes came up. To avoid that i need to disable length normalization. Can some one help me with this?? I have attached the Luke result image for your reference. In this image, document with java 50 times and oracle 6 times moved down to 11 th position. ![alt text](https://i.stack.imgur.com/tmVua.png) But this document with java 24 times and oracle 5 times is a top scorer due to the fieldnorm. ![alt text](https://i.stack.imgur.com/TTjFF.png) Hope i conveyed the info clear... If not please ask me, i ll give more info
Calculate the score only based on the documents have more occurance of term in lucene
CC BY-SA 2.5
0
2010-09-21T09:34:41.210
2012-08-29T20:55:18.027
2010-09-21T09:41:52.277
97,572
97,572
[ "c#", "java", "search", "lucene", "lucene.net" ]
3,759,013
1
3,759,029
null
4
715
What is the best way to make something like a mask with rounded corners for an image using CSS/JS/HTML? So, I need to add rounded corners to a rectangle image. I thought about adding 4 graphic elements like this one ![alt text](https://i.stack.imgur.com/hM3YJ.png) above the image at its corners to hide some little parts of the image. Here red color is, for example, for using on the red background page, and the element is for right top corner. The problem with this solution is that I can't use it on complex backgrounds, like gradients or other non-flat fill background. I know there is a masking feature that can be used in FireFox but I need some more generic solution that will work in other browsers well too. Thanks.
Add rounded corners to a rectangle raster image
CC BY-SA 2.5
0
2010-09-21T09:38:15.533
2011-02-28T11:32:55.013
null
null
135,829
[ "javascript", "html", "css", "image", "transparency" ]
3,759,487
1
3,759,655
null
0
1,771
I'm writing a custom control and I want to add a "MessageText" property of type String: ``` <Browsable(True), DefaultValue(""), Category("CustomControls"), Description("Blah."), DesignerSerializationVisibility(DesignerSerializationVisibility.Visible)> Public Property MessageText As String ``` The MessageText property is a multiline text, and the user must be able to set the text using the designer. The problem is that the designer doesn't allow to enter a newline directly for a string property. I want the same behaviour as the system TextBox's Text property, where you can click on the down arrow and write lines in the small text-editor that appears: ![](https://i.stack.imgur.com/9RiVt.png) How do I do that?
.NET 2010 custom control, multiline String property to be edited in the designer
CC BY-SA 2.5
null
2010-09-21T10:40:58.120
2010-09-21T11:06:00.237
null
null
403,335
[ "vb.net", "custom-controls" ]
3,759,785
1
3,759,814
null
1
116
I have the following code that automates a slideshow between the different slides as shown in the picture. This is now producing a fadeIn whenever I click on the numbers shown on the pic, but I'd like to automate the transition betweeh 1 to 5 and when on 5 return to 1 again on a timed maner. The screenshot is: ![alt text](https://i.stack.imgur.com/4TRt1.jpg) ``` <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> <script type="text/JavaScript"> $(document).ready(function (){ $('#button a').click(function(){ var integer = $(this).attr('rel'); $('#myslide .cover').css({left:-960*(parseInt(integer)-1)}).hide().fadeIn(); $('#button a').each(function(){ $(this).removeClass('active'); if($(this).hasClass('button'+integer)){ $(this).addClass('active')} }); }); }); </script> ```
How could I automate this fadeIn to become a slideshow?
CC BY-SA 2.5
null
2010-09-21T11:24:24.303
2010-09-21T11:36:40.217
null
null
455,178
[ "javascript", "jquery", "fadein" ]
3,759,815
1
3,798,743
null
2
3,391
Where can I find following viewer within Visual Studio? ![alt text](https://i.stack.imgur.com/UdNDi.png)
Where is the Xap file content viewer in Visual Studio?
CC BY-SA 2.5
null
2010-09-21T11:29:25.677
2010-09-26T16:33:43.937
null
null
4,035
[ "silverlight", "user-interface", "visual-studio-2010" ]
3,760,030
1
null
null
1
1,070
I need a corner like in the Maps app. ![alt text](https://i.stack.imgur.com/44Hq2.png) I tried this code but nothing happens: ``` - (IBAction) performCurl { // Curl the image up or down CATransition *animation = [CATransition animation]; [animation setDelegate:self]; [animation setDuration:1.0f]; [animation setTimingFunction:UIViewAnimationCurveEaseInOut]; [animation setType:(notCurled ? @"mapCurl" : @"mapUnCurl")]; [animation setRemovedOnCompletion:NO]; [animation setFillMode: @"extended"]; [animation setRemovedOnCompletion: NO]; notCurled = !notCurled; [[topView layer] addAnimation:animation forKey:@"pageFlipAnimation"]; ``` } This my test-project: [http://isolute.de/downloads/cornertest2.zip](http://isolute.de/downloads/cornertest2.zip)
corner like in maps App
CC BY-SA 2.5
null
2010-09-21T11:55:39.170
2011-02-28T09:51:39.607
null
null
347,741
[ "iphone", "objective-c" ]
3,761,021
1
null
null
0
38
![alt text](https://i.stack.imgur.com/AxN3P.png) I can not use the toolbar lib even with sdk 6.0 I am using 6.0 Can anyone help me .. i m stuck here
Toolbar package missing in sdk 6.0
CC BY-SA 2.5
null
2010-09-21T13:55:38.947
2010-09-21T15:34:28.760
null
null
410,693
[ "java", "blackberry" ]
3,761,080
1
3,763,107
null
1
318
i have create a gallery with jquery. [http://www.rialto-design.de/endkunden/galerie/galerie-armaturen/?album=3&gallery=2](http://www.rialto-design.de/endkunden/galerie/galerie-armaturen/?album=3&gallery=2) so my question is, how can i make the thumbs scroll left or right. when the cursor is on the right or left side of the container. ![alt text](https://i.stack.imgur.com/WW6LI.gif) Important is, the thubs are still clickable. Thx
Scroll if on the right side (jQuery)
CC BY-SA 2.5
null
2010-09-21T14:02:57.980
2010-09-22T22:44:25.000
null
null
290,326
[ "javascript", "jquery" ]
3,761,111
1
3,761,998
null
3
2,379
I'm building a small workflow application to test out the abilties of WF. What i got so far: ![Workflow example](https://i.stack.imgur.com/dRTgz.jpg) I can run the workflow and add the parameter that is used in the StartProcess operation. So the flow goes through the first decision and comes to either Invoice payment or Creditcard payment. The next part is my question: When the flow reaches the Invoce Payment sequence the next activities are called: ![Sub sequence](https://i.stack.imgur.com/QNPfK.jpg) In this sequence I call a custom activity InitiateInvoicePayment which creates a new object for storing the invoice data. At this point I want the user to fill in the rest of the required data as shown as the receive activity but here is where i am stuck. How can I stop the flow and wait for the users input, ideally trigger the client application to show a form based on a variable from the flowchart?
How to handle user input in a workflow
CC BY-SA 2.5
null
2010-09-21T14:06:37.113
2010-09-21T15:45:34.687
null
null
448,195
[ "workflow-foundation", "workflow-foundation-4" ]
3,761,757
1
3,762,526
null
3
12,964
A search key ``` --------------------------- | | A | B | C | D | --------------------------- | 1 | 01 | 2 | 4 | TextA | --------------------------- ``` An Excel sheet ``` ------------------------------ | | A | B | C | D | E | ------------------------------ | 1 | 03 | 5 | C | TextZ | | ------------------------------ | 2 | 01 | 2 | 4 | TextN | | ------------------------------ | 3 | 01 | 2 | 4 | TextA | | ------------------------------ | 4 | 22 | T | N | TextX | | ------------------------------ ``` I would like to have a function like this: f(key) -> result_row. That means: given a search key (01, 2, 4, TextA), the function should tell me that the matching row is 3 in the example above. The values in the search key (A, B, C, D) are a unique identifier. How do I get the row number of the matching row? The solution that comes first to my mind is to use Visual Basic for Application (VBA) to scan column A for "01". Once I've found a cell containing "01", I'd check the adjacent cells in columns B, C and D whether they match my search criteria. I guess that algorithm will work. But: is there a better solution? - - However, if you happen to know a solution in any higher versions of Excel or VBA, I am curious to know as well. Thank you all for your answers. @MikeD: very nice function, thank you! Here is the solution I prototyped. It's all hard-coded, too verbose and not a function as in MikeD's solution. But I'll rewrite it in my actual application to take parameters and to return a result value. ``` Sub FindMatchingRow() Dim searchKeyD As Variant Dim searchKeyE As Variant Dim searchKeyF As Variant Dim searchKeyG As Variant Const indexStartOfRange As String = "D6" Const indexEndOfRange As String = "D9" ' Initialize search key searchKeyD = Range("D2").Value searchKeyE = Range("E2").Value searchKeyF = Range("F2").Value searchKeyG = Range("G2").Value ' Initialize search range myRange = indexStartOfRange + ":" + indexEndOfRange ' Iterate over given Excel range For Each myCell In Range(myRange) foundValueInD = myCell.Offset(0, 0).Value foundValueInE = myCell.Offset(0, 1).Value foundValueInF = myCell.Offset(0, 2).Value foundValueInG = myCell.Offset(0, 3).Value isUnitMatching = (searchKeyD = foundValueInD) isGroupMatching = (searchKeyE = foundValueInE) isPortionMatching = (searchKeyF = foundValueInF) isDesignationMatching = (searchKeyG = foundValueInG) isRowMatching = isUnitMatching And isGroupMatching And isPortionMatching And isDesignationMatching If (isRowMatching) Then Range("D21").Value = myCell.Row Exit For End If Next myCell End Sub ``` This is the Excel sheet that goes with the above code: ![alt text](https://i.stack.imgur.com/ITlO6.png)
How to find a matching row in Excel?
CC BY-SA 2.5
0
2010-09-21T15:19:08.830
2010-09-22T09:33:29.157
2010-09-22T09:33:29.157
33,311
33,311
[ "vba", "excel" ]
3,762,306
1
3,893,341
null
6
4,151
I try to implement a hover effect (effect when button is pressed) through putting a semi transparent PNG file on top of the button background and the button icon. Unfortunatly the button background file is a 9-PATCH-PNG which causes some trouble here: It "swallows" everything on top of its layer and doesnt allow to cover the stretchable areas (the fine light line around) of the nine-patch-png. Removing the 9-Patch-Information is not a good solution. Here u can see my Button. The blue background is a 9 PATCH PNG. The thin light line around the button is unwanted. ![alt text](https://i.stack.imgur.com/GTIbq.png) This layer-list is assigned to the button attribute "background": ``` <?xml version="1.0" encoding="utf-8"?> <layer-list xmlns:android="http://schemas.android.com/apk/res/android"> <item android:drawable="@drawable/home_btn_bg_blue_without_padding" /> <item> <bitmap android:src="@drawable/home_icon_test" android:gravity="center" /> </item> <item android:drawable="@drawable/layer_black_50" /> </layer-list> ``` Setting the offsets of the layer to "-1" on each border is not valid. Have u guys suggestions? I tried following, which shall , suggested from [here](http://developer.android.com/guide/topics/resources/drawable-resource.html#LayerList). But didn't work either: ``` <!-- To avoid scaling, the following example uses a <bitmap> element with centered gravity: --> <item> <bitmap android:src="@drawable/image" android:gravity="center" /> </item> ``` My version (There are still the stretchable areas of the 9-patch-png uncovered): ![alt text](https://i.stack.imgur.com/Hn2dx.png) ``` <?xml version="1.0" encoding="utf-8"?> <layer-list xmlns:android="http://schemas.android.com/apk/res/android"> <item android:drawable="@drawable/home_btn_bg_blue_hover_without_padding" /> <item> <bitmap android:src="@drawable/home_icon_test" android:gravity="center" /> </item> <item> <bitmap android:src="@drawable/layer_black_100" android:height="100dp" android:width="100dp"/></item> </layer-list> ``` Could that work for me? [Making Overlaid image transparent on touch in Android?](https://stackoverflow.com/questions/3021401/making-overlaid-image-transparent-on-touch-in-android)
How to cover a 9-PATCH-PNG entirely?
CC BY-SA 2.5
0
2010-09-21T16:18:18.790
2011-02-18T18:47:39.867
2017-05-23T09:57:58.643
-1
433,718
[ "android", "android-layout", "layer", "nine-patch" ]
3,762,443
1
3,763,862
null
2
8,357
I have a client that has a simple yet complicated request for an excel sheet setup, and I can't for the world thing of where to start. I'm drawing a blank. We have a data range. Example: ``` Quarter Data 2010Q1 1 2010Q2 3 2010Q3 4 2010Q4 1 ``` I have a chart built on top of that. Change data, chart changes, protect worksheet to keep other idi... er... users from changing old data. Simple. What I want to have happen: When I add the next Q1 below Q4, the chart "automagically" selects the most recent 4Q. So when I update the data to: ``` Quarter Data 2010Q1 1 2010Q2 3 2010Q3 4 2010Q4 1 2011Q1 7 ``` The chart will show data for the last 4 quarters (2010Q2 thru 2011Q1). The goal being: keep "old" data on the same sheet, but have the charts update to most recent quarters. I'm thinking: "fixed" data locations, reverse the data (new data at top), and just insert row each new quarter: ``` Quarter Data 2011Q2 9 2011Q1 7 2010Q4 1 2010Q3 4 2010Q2 3 2010Q1 1 ``` But this will involve a lot of changes to the already existing excel sheets and I was hoping that there may be an easier/better "fix". --- EDIT: @Lance Roberts ~ Running with your suggestion: - Little more detail... The data is setup such that the column information is in A, but data for multiple tables are in B+. Table 1 is B/C. Table2 is D/E. Etc. - Data is also on a different sheet than the tables. Going by: [This Offset Description](http://www.techonthenet.com/excel/formulas/offset.php), what I've tried doing is adjusting similar to such: ``` NAME FORMULA OFFSET(range, rows, columns, height, width ) DATA0 =OFFSET('DATASHEET'!$A$2, COUNTA('DATASHEET'!$A:$A - 8, 0, 8, 1) DATA1 =OFFSET('DATASHEET'!$A$2, COUNTA('DATASHEET'!$A:$A - 8, 1, 8, 1) DATA2 =OFFSET('DATASHEET'!$A$2, COUNTA('DATASHEET'!$A:$A - 8, 2, 8, 1) ``` Goal being to tie the length/location for B/C/etc data to A. So if I add a column on A, stuff tied to Data1/2 adjust accordingly (or 3/4/5/etc, which are different charts on different sheets ) I want data cells to be picked by the first row, and then an offset number to get data x columns over. Variations on the formula don't seem to be working. 1 issue I haven't solved yet: the data is not aligning properly:![Example](https://i.stack.imgur.com/w9gtC.jpg) "Data" is always, last column under 2nd to last Quarter. Last quarter is always empty. Data is shifting to the right (in this example, under 3Q10 - NOT under the correct column. 11 should be under 4Q10. 9.5 should be under 2Q10). I know I'm getting something simple wrong... --- ![alt text](https://i.stack.imgur.com/2okPA.jpg) Seems to be working. First thing I had to change was CountA - 9 (not CountA - 8). Next was the "column offset" (0, 1, 2, 3,...). Also split some stuff up to make it more compartmentalized (I do have to train someone else how to do this for her reporting needs). Thanks Lance :)
Excel chart dynamic range-selection
CC BY-SA 2.5
0
2010-09-21T16:34:32.877
2017-01-09T19:46:45.077
2010-09-22T15:10:20.353
409,025
409,025
[ "excel", "charts", "excel-2007", "offset", "worksheet-function" ]
3,762,471
1
3,762,681
null
0
1,474
``` struct letter { char ch; struct letter *ptr_next; } *ptr_first,*ptr_this; //ptr this contains the address of the first node and ptr this contains the address of last node added. ``` ![alt text](https://i.stack.imgur.com/LUMUL.gif)A word chair has to be inserted in the linked list such that C goes into the first node,h in the second and so on.. The attached picture is the memory diagram to fill. I also added what i tried.Please guide me if i am wrong.![alt text](https://i.stack.imgur.com/a4ym4.gif) Thanks in advance..
linked list memory diagram
CC BY-SA 2.5
null
2010-09-21T16:38:39.310
2010-09-21T17:35:55.897
2010-09-21T16:53:42.270
null
null
[ "c", "linked-list" ]
3,762,542
1
3,763,033
null
12
5,075
I have a deadlock when I invoke the UI thread from a worker thread. Indeed, the worker thread is blocked on the invoke line: ``` return (ucAvancementTrtFamille)mInterfaceTraitement.Invoke(d, new object[] { psFamille }); ``` The weird thing is that the UI Thread (which, correct me if I'm wrong, is the main thread) is idle. Is there any way to: 1. see which thread I'm actually trying to invoke? 2. see what said thread is really doing? We can see in the image below, the worker thread (ID 3732) blocked on the Invoke line, and the MainThread is idle in the main function of the application. ![alt text](https://i.stack.imgur.com/57agY.jpg) Edit: Here is the stack of the main thread: ![alt text](https://i.stack.imgur.com/3ImSO.jpg) Edit2: Actually, I paused the the program a second time, and here is what the stack looks like: ![alt text](https://i.stack.imgur.com/UeiwR.jpg) Edit3: I finally found a workaround. The problem is apparently due to an async wrapper race condition issue. The workaround is to use BeginInvoke and wait for it with a timeout. When it times out, invoke it again and loop until it finally returns. Most of the time, it actually works on the second call. ``` IAsyncResult ar = mInterfaceTraitement.BeginInvoke(d, new object[] { psFamille }); while (!ar.AsyncWaitHandle.WaitOne(3000, false)) { ar = mInterfaceTraitement.BeginInvoke(d, new object[] { psFamille }); } // Async call has returned - get response ucAvancementTrtFamille mucAvancementTrtFamille = (ucAvancementTrtFamille)mInterfaceTraitement.EndInvoke(ar); ``` It's not pretty but it's the only solution I found.
Deadlock when invoking the UI thread from a worker thread
CC BY-SA 3.0
0
2010-09-21T16:48:18.407
2013-09-15T18:24:23.177
2013-09-15T18:24:23.177
41,071
194,711
[ "c#", ".net", "multithreading", "deadlock", "invoke" ]
3,762,617
1
3,763,979
null
0
420
I have a chart with some lines in a WPF application. When the line is (mouse) selected by the user I need to change its look. à la : ![alt text](https://i.stack.imgur.com/KpQti.gif) In WPF the two lines code could be as follows: ``` <Line X1= "10" Y1="20" X2="150" Y2="20" Stroke="Black" StrokeThickness="1" /> <Line X1= "10" Y1="50" X2="150" Y2="50" Stroke="Blue" StrokeThickness="3" /> <Polygon Points="80,45 80,55 90,50" Stroke="Blue" Fill="Blue" /> ``` 1. How to change the line 'style' when the user selects the object (Line)? 2. Is it possible to keep the "arrow" in the middle of the segment?
Change selection "style" in WPF
CC BY-SA 2.5
null
2010-09-21T16:58:27.763
2010-09-22T13:22:18.867
2010-09-22T13:22:18.867
185,593
185,593
[ ".net", "wpf" ]
3,762,740
1
3,873,665
null
6
1,017
I'm using gdiplus to "stroke" a textout. In certain circumstances, we see a "spike" appearing on the top or bottom of the graphic, and I'm not really sure why. We can minimize this by adjusting stroke width and font size, but thats not a good solution. I'm hoping someone can explain the problem to me. ![Spikey Bug](https://i.stack.imgur.com/PlJf0.png) And the code sample generating this 4, its outline, and the spike (unintentional) ``` GraphicsPath path(FillModeWinding); path.AddString(text,wcslen(text),&fontFamily,StateInfo.TheFont.TheWeight,(REAL)minSize,PointF((REAL)ptStart.x, (REAL)ptStart.y),&sf); // Draw the outline first if (StateInfo.StrokeWidth > 0) { Gdiplus::Color strokecolor(GetRValue(StateInfo.StrokeColor), GetGValue(StateInfo.StrokeColor), GetBValue(StateInfo.StrokeColor)); Pen pen(strokecolor,(REAL)StateInfo.StrokeWidth); graphics.SetSmoothingMode(Gdiplus::SmoothingModeAntiAlias); graphics.SetPixelOffsetMode(Gdiplus::PixelOffsetModeHighQuality); graphics.DrawPath(&pen, &path); } // Draw the text by filling the path graphics.FillPath(&solidBrush, &path); ```
FileModeWinding and DrawPath cause odd spikes to appear
CC BY-SA 2.5
null
2010-09-21T17:17:42.713
2011-06-24T14:35:58.550
2011-06-24T14:35:58.550
9,453
357,499
[ "gdi+" ]
3,762,782
1
3,765,242
null
1
1,777
I trying to port System.Drawing: public LinearGradientBrush( Rectangle rect, Color color1, Color color2, float angle ) to System.Windows.Media . I can get the angle to be correct but I can't get the start and end to be at the corners. I have tried scaling the brush's transform but that ends up messing the angle. ![alt text](https://i.stack.imgur.com/QpzYj.png) System.Drawing.Drawing2D.LinearGradientBrush: [http://msdn.microsoft.com/en-us/library/ms142563.aspx](http://msdn.microsoft.com/en-us/library/ms142563.aspx) System.Windows.Media.LinearGradientBrush: [http://msdn.microsoft.com/en-us/library/ms602517.aspx](http://msdn.microsoft.com/en-us/library/ms602517.aspx)
How to convert a System.Drawing.Drawing2D.LinearGradientBrush to a System.Windows.Media.LinearGradientBrush?
CC BY-SA 2.5
null
2010-09-21T17:22:58.703
2014-05-30T18:51:59.837
null
null
45,890
[ "wpf", "winforms", "gdi+", "system.drawing" ]
3,762,979
1
4,001,900
null
0
1,335
When Android 2.1 focuses on a text field in a WebView while in Landscape, it does this below. It takes the entire field input area and fills the tiny strip of available screen. The problem here is that when you hit that "Next" button, you have enough idea what field you are in. Is there a way to improve this with some sort of prompt so the user at least knows the type of data they are expected to enter in that field? I tried using a ``` <label for="my_field_id">My Caption</label> <input type="text" id="my_field_id"/> ``` hoping that it would pull text from there, but it seemed to have no effect. --- Also, I just tried adding a `placeholder="Foo Bar"` to the input field. This sort of worked. The prompt appeared in the field, and when tapped it appeared in the fullscreen input area. But the problem was that the placeholder was kind of editable text, but not really. The cursor placement and input just sort of behaved buggy and strange as it couldn't deleted, but new input would write over it. It was not a pleasant user experience :( ![alt text](https://i.stack.imgur.com/IkWRR.jpg)
Android 2.1 WebView and keyboard input
CC BY-SA 2.5
null
2010-09-21T17:46:04.010
2010-12-14T22:09:12.567
2010-09-21T18:11:26.673
62,076
62,076
[ "html", "android", "webview" ]
3,763,635
1
3,763,760
null
3
2,002
In IB, on the .xib where the file's owner is a subclass of UITableViewController, the structure of a cell that I wish to load from the xib is: (UITableViewCell)cell->(UIView)View->(UIButton)but1,but2,but3. I am trying to have the buttons appear on the table without the frame/background of the cell. I've made the cell's background and its View's background clearColor, but what I get now is a black background on the cell (with the rounded corners), like so: ![alt text](https://i.stack.imgur.com/iXDro.png) Because of the striped nature of the tableview's background, if I choose that same background for the cell then the stripes won't align perfectly, so it is not acceptable. I just need the damn cell to be translucent, I don't know where the black is coming from. Any ideas?
How to make background of UITableViewCell with buttons transparent
CC BY-SA 2.5
0
2010-09-21T19:14:58.587
2010-09-21T19:30:40.280
null
null
127,819
[ "iphone", "sdk", "uitableview", "background" ]
3,763,640
1
null
null
69
18,669
> [How do you implement a “Did you mean”?](https://stackoverflow.com/questions/41424/how-do-you-implement-a-did-you-mean) I am writing an application where I require functionality similar to Google's "did you mean?" feature used by their search engine: ![alt text](https://i.stack.imgur.com/cZCpI.jpg) Is there source code available for such a thing or where can I find articles that would help me to build my own?
Where can I learn more about the Google search "did you mean" algorithm?
CC BY-SA 2.5
0
2010-09-21T19:15:19.783
2010-09-23T16:39:26.203
2017-05-23T12:19:44.807
-1
439,782
[ "algorithm", "nlp", "spell-checking" ]
3,763,664
1
null
null
1
277
I want to add two table or more consecutively and they must be seemed like one table. ``` <html> <head> <style type="text/css"> .cls { border:1px solid #000000; } .cls td { border:1px solid #000000; } </style> </head> <body> <table class="cls"> <tr> <td>aaa</td><td>bbb</td><td>ccc</td> </tr> <tr> <td>ddd</td><td>eee</td><td>fff</td> </tr> </table> <table class="cls"> <tr> <td>aaa</td><td>bbb</td><td>ccc</td> </tr> <tr> <td>ddd</td><td>eee</td><td>fff</td> </tr> </table> </body> </html> ``` My problem is the line that tables combined has a doble line normally. How can i show it like a single line. ![alt text](https://i.stack.imgur.com/IlB3y.jpg)
Removing table line
CC BY-SA 2.5
null
2010-09-21T19:19:19.643
2010-09-21T19:28:31.733
null
null
134,263
[ "html", "css" ]
3,763,811
1
null
null
9
1,323
In my project I'm using EntityFramework 4 for working with data. I found horrible performance problems with a simple query. When I looked at the profiler on a sql query, generated by EF4, I was shocked. I have some tables in my entity data model: ![Data Model](https://i.stack.imgur.com/xW1Bx.png) It looks pretty simple. I'm trying to select all product items from specified category with all related navigation properties. I wrote this LINQ query: ``` ObjectSet<ProductItem> objectSet = ...; int categoryId = ...; var res = from pi in objectSet.Include("Product").Include("Inventory").Include("Inventory.Storage") where pi.Product.CategoryId == categoryId select pi; ``` EF generated this sql query: ``` SELECT [Project1].[pintId1] AS [pintId], [Project1].[pintId] AS [pintId1], [Project1].[intProductId] AS [intProductId], [Project1].[nvcSupplier] AS [nvcSupplier], [Project1].[ nvcArticle] AS [ nvcArticle], [Project1].[nvcBarcode] AS [nvcBarcode], [Project1].[bIsActive] AS [bIsActive], [Project1].[dtDeleted] AS [dtDeleted], [Project1].[pintId2] AS [pintId2], [Project1].[nvcName] AS [nvcName], [Project1].[intCategoryId] AS [intCategoryId], [Project1].[ncProductType] AS [ncProductType], [Project1].[C1] AS [C1], [Project1].[pintId3] AS [pintId3], [Project1].[intProductItemId] AS [intProductItemId], [Project1].[intStorageId] AS [intStorageId], [Project1].[dAmount] AS [dAmount], [Project1].[mPrice] AS [mPrice], [Project1].[dtModified] AS [dtModified], [Project1].[pintId4] AS [pintId4], [Project1].[nvcName1] AS [nvcName1], [Project1].[bIsDefault] AS [bIsDefault] FROM (SELECT [Extent1].[pintId] AS [pintId], [Extent1].[intProductId] AS [intProductId], [Extent1].[nvcSupplier] AS [nvcSupplier], [Extent1].[ nvcArticle] AS [ nvcArticle], [Extent1].[nvcBarcode] AS [nvcBarcode], [Extent1].[bIsActive] AS [bIsActive], [Extent1].[dtDeleted] AS [dtDeleted], [Extent2].[pintId] AS [pintId1], [Extent3].[pintId] AS [pintId2], [Extent3].[nvcName] AS [nvcName], [Extent3].[intCategoryId] AS [intCategoryId], [Extent3].[ncProductType] AS [ncProductType], [Join3].[pintId1] AS [pintId3], [Join3].[intProductItemId] AS [intProductItemId], [Join3].[intStorageId] AS [intStorageId], [Join3].[dAmount] AS [dAmount], [Join3].[mPrice] AS [mPrice], [Join3].[dtModified] AS [dtModified], [Join3].[pintId2] AS [pintId4], [Join3].[nvcName] AS [nvcName1], [Join3].[bIsDefault] AS [bIsDefault], CASE WHEN ([Join3].[pintId1] IS NULL) THEN CAST(NULL AS int) ELSE 1 END AS [C1] FROM [ProductItem] AS [Extent1] INNER JOIN [Product] AS [Extent2] ON [Extent1].[intProductId] = [Extent2].[pintId] LEFT OUTER JOIN [Product] AS [Extent3] ON [Extent1].[intProductId] = [Extent3].[pintId] LEFT OUTER JOIN (SELECT [Extent4].[pintId] AS [pintId1], [Extent4].[intProductItemId] AS [intProductItemId], [Extent4].[intStorageId] AS [intStorageId], [Extent4].[dAmount] AS [dAmount], [Extent4].[mPrice] AS [mPrice], [Extent4].[dtModified] AS [dtModified], [Extent5].[pintId] AS [pintId2], [Extent5].[nvcName] AS [nvcName], [Extent5].[bIsDefault] AS [bIsDefault] FROM [Inventory] AS [Extent4] INNER JOIN [Storage] AS [Extent5] ON [Extent4].[intStorageId] = [Extent5].[pintId]) AS [Join3] ON [Extent1].[pintId] = [Join3].[intProductItemId] WHERE [Extent2].[intCategoryId] = 8 /* @p__linq__0 */) AS [Project1] ORDER BY [Project1].[pintId1] ASC, [Project1].[pintId] ASC, [Project1].[pintId2] ASC, [Project1].[C1] ASC ``` For 7000 records in database and ~1000 record in specified category this query's execution time id around 10 seconds. It is not surprising if look at this: ``` FROM [ProductItem] AS [Extent1] INNER JOIN [Product] AS [Extent2] ON [Extent1].[intProductId] = [Extent2].[pintId] LEFT OUTER JOIN [Product] AS [Extent3] ON [Extent1].[intProductId] = [Extent3].[pintId] ***LEFT OUTER JOIN (SELECT ....*** ``` Nested select in join... Horrible... I tried to change LINQ query, but I get same SQL query outputted. A solution using stored procedures is not acceptable for me, because I'm using SQL Compact database.
Linq queries in Entity Framework 4. Horrible performance
CC BY-SA 3.0
null
2010-09-21T19:38:55.910
2017-04-15T16:29:02.090
2017-04-15T16:29:02.090
1,033,581
454,362
[ "c#", ".net", "entity-framework", "orm", "performance" ]
3,763,948
1
null
null
0
1,712
Using a dropdown menu, I'm to figure out The code I have so far uses a button to do the queries. (For now only viewing the "View All" --or view specific product type works. The "order by price" high to low, low to high, will be posted as a different question on this site.) ``` <!--category and price form ------------------------- --> <form action="register_script.php" name="frm" method="post"> <select name="category" id="category"> <option value="viewall">View All</option> <option value="dress">Dress</option> <option value="athletic">Athletic</option> <option value="sandals">Sandals</option> </select> <input type="submit" value="Go" /> </form> <form action="register_script.php" name="frm" method="post"> <select name="price" id="price"> <option value="lowToHigh">Low to High</option> <option value="highToLow">High to Low</option> </select> <input type="submit" name="orderPrice" value="orderPrice" /> </form> </div> <?php function categoryList($pUserCat=false) { echo "I am in category list" . "<br/>"; $con = getConnection(); $sqlQuery = "SELECT * from Products"; if($pUserCat == "athletic") { $sqlQuery = "SELECT * from Products WHERE ProductType='athletic'"; } elseif ($pUserCat == "dress") { $sqlQuery = "SELECT * from Products WHERE ProductType='dress'"; } elseif ($pUserCat == "sandals") { $sqlQuery = "SELECT * from Products WHERE ProductType='sandals'"; } elseif ($pUserCat == "viewall") { $sqlQuery = "SELECT * from Products"; } // Execute Query ----------------------------- $result = mysqli_query($con, $sqlQuery); if(!$result) { echo "Cannot do query" . "<br/>"; exit; } $row = mysqli_fetch_row($result); $count = $row[0]; if ($count > 0) { echo "Query works" . "<br/>"; } else { echo "Query doesn't work" ."<br/>"; } // Display Results ----------------------------- $num_results = mysqli_num_rows($result); for ($i=0; $i<$num_results; $i++) { $row = mysqli_fetch_assoc ($result); // print_r($row); echo '<img src="data:image/jpeg;base64,'.base64_encode($row['Image']).'" />'; echo "Price: " . stripslashes($row['Price']); } // Close connection closeConnection($con); } ?> ``` ![alt text](https://i.stack.imgur.com/p8eLA.png)
Activate SQL query without using a form button using PHP and not JavaScript
CC BY-SA 2.5
null
2010-09-21T19:56:07.247
2010-09-21T20:26:21.067
2010-09-21T20:26:21.067
147,463
422,157
[ "php", "javascript", "forms" ]
3,764,124
1
3,765,337
null
6
2,542
I have a VB6 project that references COMSVCSLib and one of the methods makes calls to COMSVCSLib's SharedPropertyGroupManager.CreatePropertyGroup passing and as parameters. ``` Dim groupName As String Dim spmMgr As COMSVCSLib.SharedPropertyGroupManager Dim spmGroup As COMSVCSLib.SharedPropertyGroup Dim bGroupExists As Boolean Set spmMgr = New COMSVCSLib.SharedPropertyGroupManager With spmMgr Set spmGroup = .CreatePropertyGroup(groupName, LockMethod, Process, bGroupExists) End With ``` Having not worked with VB6 for several years now, at first I thought LockMethod and Process were variables or constants defined somewhere else within the project. After a little research on the Object Browser I found out that they were both being exposed as constants in COMSVCSLib. ![Object Browser](https://i.stack.imgur.com/uyjaC.png) But looking at their definition in OLE/COM Object Viewer, they seem to be defined as values of an enumeration: ``` typedef enum { LockSetGet = 0, LockMethod = 1 } __MIDL___MIDL_itf_autosvcs_0469_0002; ```
Why aren't TypeLib enums exposed as enums in Visual Basic 6.0?
CC BY-SA 2.5
0
2010-09-21T20:17:51.780
2010-09-24T22:56:45.640
null
null
151,249
[ "vb6", "enums", "constants", "typelib" ]
3,764,221
1
null
null
1
9,672
I'm in the process of learning how to create an e-commerce site. I'm trying to figure out how to order product results by price. Code below is a menu list to either filter a specific product category or the option to view all products--the code for that works. I'm not sure how to add code to "sort by price" (low to high, high to low). I've tried creating a function called `priceList` and calling inside the function `categoryList` (which queries the database for which product type or to view all products), but does not work. ``` function priceList() { $con = getConnection(); if($pUserCat == "lowToHigh") { $sqlQuery = "SELECT Price from Products ORDER BY Price ASC"; } elseif($pUserCat == "highToLow") { $sqlQuery = "SELECT Price from Products ORDER BY Price DESC"; // Execute Query ----------------------------- $result = mysqli_query($con, $sqlQuery); if(!$result) { echo "Cannot do query" . "<br/>"; exit; } $row = mysqli_fetch_row($result); $count = $row[0]; if ($count > 0) { echo "Query works" . "<br/>"; } else { echo "Query doesn't work" ."<br/>"; } // Display Results ----------------------------- $num_results = mysqli_num_rows($result); for ($i=0; $i<$num_results; $i++) { $row = mysqli_fetch_assoc ($result); // print_r($row); echo '<img src="data:image/jpeg;base64,'.base64_encode($row['Image']).'" />'; echo "Price: " . stripslashes($row['Price']); } // Close connection closeConnection($con); } ``` ``` <!--category and price form ------------------------- --> <form action="register_script.php" name="frm" method="post"> <select name="category" id="category"> <option value="viewall">View All</option> <option value="dress">Dress</option> <option value="athletic">Athletic</option> <option value="sandals">Sandals</option> </select> <input type="submit" value="Go" /> </form> <form action="register_script.php" name="frm" method="post"> <select name="price" id="price"> <option value="lowToHigh">Low to High</option> <option value="highToLow">High to Low</option> </select> <input type="submit" name="orderPrice" value="orderPrice" /> </form> </div> ``` ``` <?php function categoryList($pUserCat=false) { echo "I am in category list" . "<br/>"; $con = getConnection(); $sqlQuery = "SELECT * from Products"; if($pUserCat == "athletic") { $sqlQuery = "SELECT * from Products WHERE ProductType='athletic'"; } elseif ($pUserCat == "dress") { $sqlQuery = "SELECT * from Products WHERE ProductType='dress'"; } elseif ($pUserCat == "sandals") { $sqlQuery = "SELECT * from Products WHERE ProductType='sandals'"; } elseif ($pUserCat == "viewall") { $sqlQuery = "SELECT * from Products"; } // Execute Query ----------------------------- $result = mysqli_query($con, $sqlQuery); if(!$result) { echo "Cannot do query" . "<br/>"; exit; } $row = mysqli_fetch_row($result); $count = $row[0]; if ($count > 0) { echo "Query works" . "<br/>"; } else { echo "Query doesn't work" ."<br/>"; } // Display Results ----------------------------- $num_results = mysqli_num_rows($result); for ($i=0; $i<$num_results; $i++) { $row = mysqli_fetch_assoc ($result); // print_r($row); echo '<img src="data:image/jpeg;base64,'.base64_encode($row['Image']).'" />'; echo "Price: " . stripslashes($row['Price']); } // priceList(); $priceOrder = getPriceBtn(); //$priceOrder holds value of option selected in //price order menu priceList($priceOrder); // Close connection closeConnection($con); } function getPriceBtn() { //echo "<br/>"."I am calling getPriceBtn function" . "<br/>"; $priceBtn = $_POST["orderPrice"]; // price button return $price; //echo $priceBtn; } ?> ``` ![alt text](https://i.stack.imgur.com/XJboC.png)
Filter results by Product Type and Sort List by Price (PHP/SQL)
CC BY-SA 2.5
null
2010-09-21T20:30:26.390
2010-09-21T21:14:28.377
2010-09-21T21:14:28.377
422,157
422,157
[ "php", "sql" ]
3,764,410
1
3,764,488
null
3
2,192
I have a Python application and I decided to do a .exe to execute it. This is the code that I use to do the .exe: ``` # -*- coding: cp1252 -*- from distutils.core import setup import py2exe, sys, os sys.argv.append('py2exe') setup( options = {'py2exe': {'bundle_files': 1}}, windows = [{'script': "SoundLog.py"}], zipfile = None, packages=[r"C:\Users\Public\SoundLog\Code\Código Python\SoundLog\Auxiliar", r"C:\Users\Public\SoundLog\Code\Código Python\SoundLog\Plugins"], ) ``` But when I run my application with the .exe, the graphics are quite different. In the image bellow you can see the application running thought python at the left and running thought the .exe at the right. ![alt text](https://i.stack.imgur.com/JCsU3.png) How can I make the .exe one be as good as the one that runs thought python?
How to make a .exe for Python with good graphics?
CC BY-SA 2.5
0
2010-09-21T20:55:43.240
2013-04-19T22:29:25.150
null
null
187,730
[ "python", "graphics", "wxpython", "py2exe" ]
3,764,486
1
null
null
5
2,665
I am having trouble deciphering a WCF trace file, and I hope someone can help me determine where in the pipeline I am incurring latency. The trace for "Processing Message XX" is shown below, where there appears to be 997ms delay between the Activity Boundary and the transfer to "Process Action" where my service code is executed (which takes approx 50ms). ![Processing Message trace](https://i.stack.imgur.com/wI7sY.jpg) First, I am unsure whether I am right in understanding the "Time" column to represent start time for the activity item. I believe this to be the case because, drilling into the "Processing action" trace displays a list of activities with the first timestamp equal to the timestamp shown in the above trace for the "Processing action" item. My primary question is this: how do I determine what is happening during this 997ms time span? As I read about the service trace viewer, it seems that this activity type involves "transport or security processing", which leads me to believe it is a network issue, but I cannot be sure. In case it is relevant, below is a snapshot of the drill-down to "Process action" trace. ![Processing Action trace](https://i.stack.imgur.com/as2ND.jpg) Does anyone have some insight on how to drill further into this activity to pinpoint the cause of delay? Thank you in advance!
WCF Trace Log analysis - help
CC BY-SA 2.5
null
2010-09-21T21:08:31.977
2012-10-05T13:21:53.257
null
null
67,538
[ "wcf", "performance", "trace" ]
3,764,651
1
3,844,849
null
3
1,927
Here are my requirements: - - - - `mouseout`- `mouseover`- Here's an example of what I'd like to do: ![alt text](https://i.stack.imgur.com/nPIPq.png)
Tooltip as toolbar: jQuery, CSS, or...?
CC BY-SA 2.5
0
2010-09-21T21:29:22.413
2013-01-30T09:43:47.687
null
null
373,496
[ "jquery", "css", "jquery-plugins", "tooltip" ]
3,764,699
1
3,765,008
null
5
24,761
I have the weirdest bug ever... I'm experimenting with display: table, and my proof of concept works on the very first try after opening a new process, but any subsequent reloading of the page breaks the design. Here is the simple HTML page: ``` <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Untitled Page</title> <style> .container { display: table; } .row { display: table-row; } .cell { display: table-cell; width: 100px; height: 100px; border: 1px solid blue; padding: 1em; } </style> </head> <body> <div class="container"> <div class="row"> <div class="cell">CELL A</div> <div class="cell">CELL B</div> <div class="cell">CELL C</div> </div> </div> </body> </html> ``` And here is the expected result, this is what I get after loading the first time. ![alt text](https://i.stack.imgur.com/oQ3ZQ.gif) Now that's what I get after reloading the page, with F5: ![alt text](https://i.stack.imgur.com/bdAQi.gif) It's insane!!! Can someone please try it and let me know how it comes out for them? Thank you. I hope I will not have killed myself by the time I read the solution :-)
Internet Explorer 8 bug with display: table
CC BY-SA 3.0
0
2010-09-21T21:37:39.803
2013-05-10T16:26:23.733
2013-05-10T16:26:23.733
303,468
303,468
[ "css", "internet-explorer", "internet-explorer-8" ]
3,765,495
1
3,765,563
null
3
4,390
on the backend on symfony 1.4 / Doctrine, you have a tool which allows you to filter data according to date, location, age (and many more according to your model) ![enter image description here](https://i.stack.imgur.com/dnWI3.png) I'm searching a way to do the same (with some customisation such as removing some fields) but in the . I didn't find any documentation on how to do it Do you have an idea ?
Symfony : How to filter data on the frontend like in the backend
CC BY-SA 3.0
0
2010-09-22T00:36:49.220
2012-08-05T08:58:03.057
2012-08-05T08:58:03.057
569,101
318,071
[ "php", "symfony1", "filtering", "frontend" ]
3,765,952
1
3,765,965
null
1
843
Is it possible to have the keyboard show inside a UIPopOver instead of filling the screen width? something like the image... ![alt text](https://i.stack.imgur.com/QOt97.png)
ipad - keyboard inside popover?
CC BY-SA 3.0
null
2010-09-22T02:39:54.120
2014-10-09T10:54:29.587
2014-10-09T10:54:29.587
759,866
316,469
[ "ipad" ]
3,766,115
1
null
null
-1
70
Am simply executing query , The record count just 2980 , but it allocate around 2MB , I dont How its 2mb, just rendering records without css , how to track , For what reason it showing as 2MB , ![alt text](https://i.stack.imgur.com/rKsW7.gif)
Firefox showing records size as 2MB ,
CC BY-SA 2.5
null
2010-09-22T03:29:28.090
2010-09-22T03:42:01.507
null
null
246,963
[ "php", "mysql", "performance" ]
3,766,612
1
null
null
1
419
Looking at below UML diagram (decorator pattern), what is the name of relationship between Decorator and component? Is it Association? ![Decorator pattern](https://i.stack.imgur.com/yDiiU.gif)
UML notation: What is this relationship?
CC BY-SA 3.0
null
2010-09-22T05:42:00.913
2015-04-29T20:02:22.077
2015-04-29T20:02:22.077
208,997
61,156
[ "uml" ]
3,767,066
1
3,767,305
null
0
1,056
Following [this tutorial](http://blog.jayway.com/2009/03/22/uitoolbars-in-iphone-os-2x/) and [this question](https://stackoverflow.com/questions/3722450/navigation-controller-that-doesnt-use-the-whole-screen), I attempted to create a custom `UIViewController` containing a `UINavigationController`. This mostly worked, except that the controller takes up the full screen and so the status bar overlaps it. Downloading the tutorial's source and running it, I found that the tutorial had the same problem (it uses a `UITableViewController`). Further experimentation revealed that it works if the content of the custom controller is a `UILabelView` instead. ![alt text](https://i.stack.imgur.com/Qfu0s.png)
Layered UIViewControllers overlaps status bar
CC BY-SA 2.5
null
2010-09-22T07:16:12.943
2010-09-23T00:35:36.050
2017-05-23T10:30:24.960
-1
165,495
[ "iphone", "cocoa-touch", "uiviewcontroller" ]
3,767,606
1
3,767,656
null
7
2,161
My problem is similar to [this](https://stackoverflow.com/questions/2605133/how-do-i-get-co-ordinates-of-selected-text-in-an-html-using-javascript-document-g), but I need a way to get the coordinates of the right side of the selection with Javascript in Firefox. I made a small example to show what I mean: ![alt text](https://i.stack.imgur.com/NRoAT.png) The code I got from the other post is the following: ``` var range = window.getSelection().getRangeAt(0); var dummy = document.createElement("span"); range.insertNode(dummy); var box = document.getBoxObjectFor(dummy); var x = box.x, y = box.y; dummy.parentNode.removeChild(dummy); ``` This gives me the coordinates of the beginning of the selection. Is there any way to retrieve the coordinates of the end of the selection?
How to get the coordinates of the end of selected text with javascript?
CC BY-SA 2.5
0
2010-09-22T08:42:37.340
2013-07-06T16:01:30.293
2017-05-23T10:30:24.960
-1
423,350
[ "javascript", "firefox", "getselection" ]
3,767,696
1
3,809,710
null
1
9,796
I have implemented an autocomplete in my app for zip codes. I am debugging in Firebug and I see in my console that the action is performing and I get a list of zip codes in the list of results, but the actual list is not displaying when I debug. Here's the action in my Customers controller: ``` //the autocomplete request sends a parameter 'term' that contains the filter public ActionResult FindZipCode(string term) { string[] zipCodes = customerRepository.FindFilteredZipCodes(term); //return raw text, one result on each line return Content(string.Join("\n", zipCodes)); } ``` Here's the markup (abbreviated) ``` <% using (Html.BeginForm("Create", "Customers")) {%> <input type="text" value="" name="ZipCodeID" id="ZipCodeID" /> <% } %> ``` and here's the order I load my scripts: ``` <script type="text/javascript" src="/Scripts/jquery-1.4.2.js"></script> <script type="text/javascript" src="/Scripts/jquery.ui.core.js"></script> <script type="text/javascript" src="/Scripts/jquery.ui.widget.js"></script> <script type="text/javascript" src="/Scripts/jquery.ui.position.js"></script> <script type="text/javascript" src="/Scripts/jquery.ui.autocomplete.js"></script> <script type="text/javascript"> $(document).ready(function() { $("#ZipCodeID").autocomplete({ source: '<%= Url.Action("FindZipCode", "Customers") %>'}); }); </script> ``` Anything obvious that I'm missing? Like I say the script is grabbing the list of zip codes, they just won't display on my page when I test. EDIT: I added an image that shows what I see in firebug - it appears that I get my zip codes back, but just won't display the dropdown. ![](https://i65.photobucket.com/albums/h208/bsirrah/autocompleteproblem.png) I also updated my text box so that it's inside of the ui-widget div like so: ``` <div class="ui-widget"> <input type="text" name="ZipCodeID" id="ZipCodeID" /> </div> ``` and this is the script that I'm using: ``` <script type="text/javascript"> $(document).ready(function() { $("#ZipCodeID").autocomplete('<%= Url.Action("FindZipCode", "Customers") %>'); }); </script> ```
ASP.Net MVC Jquery UI Autocomplete - list not showing up when I debug
CC BY-SA 2.5
0
2010-09-22T08:57:25.880
2010-09-28T04:34:07.940
2017-02-08T14:30:22.787
-1
209,081
[ "c#", "asp.net-mvc", "jquery-autocomplete" ]