Search Results

Search found 1813 results on 73 pages for 'vertical'.

Page 9/73 | < Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >

  • Vertical Seek not progress value not showing on MainActivity textView

    - by Raju Gujarati
    I am try to display the progress value of the seekBar but when it comes to the execution, there is no update on the value being display on the TextView. I wonder what alternatives than putting two classes onto one big class in order to archive this aim ? The below is my code VerticalSeekBar.java package com.example.imagerotation; import android.content.Context; import android.graphics.Canvas; import android.util.AttributeSet; import android.view.MotionEvent; import android.widget.SeekBar; import android.widget.Toast; public class VerticalSeekBar extends SeekBar { public VerticalSeekBar(Context context) { super(context); } public VerticalSeekBar(Context context, AttributeSet attrs, int defStyle) { super(context, attrs, defStyle); } public VerticalSeekBar(Context context, AttributeSet attrs) { super(context, attrs); } protected void onSizeChanged(int w, int h, int oldw, int oldh) { super.onSizeChanged(h, w, oldh, oldw); } @Override protected synchronized void onMeasure(int widthMeasureSpec, int heightMeasureSpec) { super.onMeasure(heightMeasureSpec, widthMeasureSpec); setMeasuredDimension(getMeasuredHeight(), getMeasuredWidth()); } protected void onDraw(Canvas c) { c.rotate(-90); c.translate(-getHeight(), 0); super.onDraw(c); } @Override public boolean onTouchEvent(MotionEvent event) { if (!isEnabled()) { return false; } switch (event.getAction()) { case MotionEvent.ACTION_DOWN: case MotionEvent.ACTION_MOVE: case MotionEvent.ACTION_UP: int progress = getMax() - (int) (getMax() * event.getY() / getHeight()); setProgress(progress); onSizeChanged(getWidth(), getHeight(), 0, 0); //Toast.makeText(getContext(), String.valueOf(progress), Toast.LENGTH_SHORT).show(); break; case MotionEvent.ACTION_CANCEL: break; } return true; } } MainActvity.java package com.example.imagerotation; import android.app.Activity; import android.os.Bundle; import android.view.Menu; import android.view.MenuItem; import android.widget.TextView; public class MainActivity extends Activity { private VerticalSeekBar seek; private TextView by; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); seek = (VerticalSeekBar)findViewById(R.id.seekBar1); by = (TextView)findViewById(R.id.textView1); by.setText(String.valueOf(seek.getProgress())); } }

    Read the article

  • Transponse the data from vertical to horizondal using vba

    - by raam
    I wants to popualte the data in MS-Access into Excel for this i am using VBA This is my code varConnection = "ODBC; DSN=MS Access Database;DBQ=D:\sample\table.accdb; Driver={Driver do Microsoft Access (*.accdb)}" varSQL = "SELECT * FROM LeftPanes" With ActiveSheet.QueryTables.Add(Connection:=varConnection, Destination:=ActiveSheet.Range("B4")) .CommandText = varSQL .Name = "Query-39008" .Refresh BackgroundQuery:=False End With Its working Properly it retrive data and display in the correct sheet my problem is that this code display the retrived date in vertically view i needs horizondal view. it is possible to display in horizondal view please any one guide me . Thanks in advance

    Read the article

  • AJAX Autocomplete appears at a random vertical position, not touching the textbox

    - by Tim
    Hi, I am using the AJAX Autocomplete extender for ASP.NET 2. Everything works fine...I am calling a webservice which gets me the values to fill the drop down with after 3 letters are typed into certain es. I have set the maxheight attribute and am using a scrollbar in case there are more entries than would fit that height. However, I notice that in some cases, the drop down appears at a random position on the screen, i.e. rather than connected to the relevant textbox, sometimes it appears with its entries above the textbox, not touching it at all. Sometimes it would have just one entry and it would appear in the middle of the screen vertically above the textbox it is associated to. Is there a reason why this is happening?

    Read the article

  • Flex having a VBox with Vertical Buttons.

    - by James_Dude
    Hi I am trying to get a left hand like panel bar in my application, one much like the OneNote left hand(notebook) panel. I have been trying to use a VBox with Buttons and setting the rotation on the buttons to 90. The buttons seem to disappear when I do this. An example of what I am trying to achieve is here: http://www.rid00z.net/panelBarExample.png What is the best way to achieve Vertically stacked buttons like this?

    Read the article

  • Rendering sub tools on vertical toolbar

    - by user146780
    I was wondering how ex Photoshop and Expression Design render sub tools. These show up when for example you hold your mouse down on the fill tool, a sub menu comes up to your right with the fill and gradient tools. I'm just not sure how to go about this because this sub menu would essentially have to be an extension of my toolbar, but then it would find itself on my Frame control. How is this handled? Would it be a good idea to just paint on my frame?

    Read the article

  • Vertically Align text in a Div

    - by shinjuo
    I am trying to find the most effective way to align text with a div. I have tried a few things and none seem to work. .testimonialText { position: absolute; left: 15px; top: 15px; width: 150px; height: 309px; vertical-align: middle; text-align: center; font-family: Georgia, "Times New Roman", Times, serif; font-style: italic; padding: 1em 0 1em 0; }

    Read the article

  • In LaTeX, is there a way to get long lines along the margins?

    - by Christian Jonassen
    I'm working on a report, and some elements are outside the margins (but some are just barely outside the margins). I was wondering: Is there a way to make two vertical lines, one on each side, along the margins so that one can easily see if it goes outside them? (Googling it, I only found information about margin notes.) A figure is below: |report text goes here| |more text goes also h|ere |and so on and so fort|h It would certainly make correcting these kinds of mistakes very trivial. :) Feel free to post answers that would solve/show this problem in a more "LaTeX-correct" way, if that makes any sense at all.

    Read the article

  • Vertically center CSS techniques don't work in Chrome

    - by at.
    I've gone through stackoverflow questions and a whole bunch of articles on vertically centering text like the following: http://blog.themeforest.net/tutorials/vertical-centering-with-css/ None of the techniques seem to work with the latest version of Chrome. Is that just the nature of Chrome? My text just always appears at the top. It seems that whenever I use 50% or 100% as values for CSS's height or top, nothing happens. I just need a single line of text vertically centered. line-height isn't helpful because I want it centered in the middle of the browser window... I don't know how tall the browser window is going to be. UPDATE: The problem is apparently Foundation 4. Once I delete the following everything works as expected: <link href="/assets/foundation_and_overrides.css?body=1" media="screen" rel="stylesheet" /> Any idea on how to make it work with Foundation 4?

    Read the article

  • How to Vertically Center Icons on a Line?

    - by jeremy
    What's the best way to center icons on a line when the icons are smaller than the line height? For example (styles inline for easier reading): <div style="line-height: 20px"> <img style="width: 12px; height: 12px;"/> Blah blah blah </div> I want the img to be centered on a single line of the div, above. That is, even if the text wrapped to multiple lines, the image would be centered against a single line. Ideally, the solution would not involve setting margings/paddings on the image and would work even if I didn't know the line-height. Things I've read: How do I vertically align text next to an image with CSS? (deals with case where image is larger, doesn't seem to apply here) Understanding vertical-align

    Read the article

  • centering image vertically in all resolutions

    - by gnomixa
    I need to be able to center the image vertically for all the common resolutions. A lot of ppl here on SO have already asked this question before, and 90% of then give this tutorial http://www.jakpsatweb.cz/css/css-vertical-center-solution.html as an answer. However, when viewed at my 1280 by 1024 res monitor in FF, it's not centered. And worse yet, it breaks horribly in IE7. So, it's definitely NOT the answer. Am I chasing the impossible dream? The solution has to work for FF and IE 6/7 the solution can be anything that would work, though being a bit of a purist, I would prefer a div over table:)

    Read the article

  • Request of some opinions about a vertical menu style and some suggestions for the site style [on hold]

    - by AndreaNobili
    I am developing a simple mainly static website using WordPress (because maybe in the future I will add some dynamic content) for a company. The new site have to follow the structure of the old site that requires the presence of a vertical main menu in the left column that contains the link to all the statics pages in the site. This is the old site structure: http://www.saranistri.com/ Now I have installed a new WordPress test site (this is only a test site): http://onofri.org/example/ As you can see in the left columns I have put two main menu vetical widgets that implements a possible choise for the maun menù (the top menù upon the header must be eliminated in the final implementation) I want to know some opinions about: 1) Which of the two version is better? Do you have some additional ideas about the CSS style of this vertical menu? 2) What could I do to give a more professional look to this site? (I know that I have to insert a logo into the header) Tnx Andrea

    Read the article

  • Vertically center a fluid image in a fluid container

    - by Ferdy
    I certainly do not want to add to the pile of vertical alignments CSS questions, but I've spent hours trying to find a solution to no avail yet. Here's the situation: I am building a slideshow gallery of images. I want the images to be displayed as large as the user's window allows. So I have this outer placeholder: <section class="photo full"> (Yes, I'm using HTML5 elements). Which has the following CSS: section.photo.full { display:inline-block; width:100%; height:100%; position:absolute; overflow:hidden; text-align:center; } Next, the image is placed inside it. Depending on the orientation of the image, I set either the width or height to 75%, and the other axis to auto: $wide = $bigimage['width'] >= $bigimage['height'] ? true: false; ?> <img src="<?= $bigimage['url'] ?>" width="<?= $wide? "75%" : "auto"?>" height="<?= $wide? "auto" : "75%"?>"/> So, we have a fluid outer container, with inside a fluid image. The horizontal centering of the image works, yet I cannot seem to find a way to vertically center the image within it's container. I have researched centering methods but most assume either the container or image has a known width or height. Then there is the display:table-cell method, which does not seem to work for me either. I'm stuck. I'm looking for a CSS solution, but am open to js solutions too.

    Read the article

  • Vertically Aligning Elements

    - by Naz
    I'm trying to understand how to center elements within a div. I have this basic code I am working with and am trying to get the 'This is a button' element to be in the center <body> <div style="width:960px;background-color:#d7d7d7;"> <div style=" width:400px; padding:10px; height:auto; background-color:#006699; display:inline-block; "> <p> Vivamus vel sapien. Praesent nisl tortor, laoreet eu, dapibus quis, egestas non, mauris. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Vivamus vel sapien. Praesent nisl tortor, laoreet eu, dapibus quis, egestas non, mauris. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.</p> </div> <div style=" width:100px; padding:10px; height:auto; background-color:#b1b1b1; float:right; display:inline-block; margin:auto!important; vertical-align:middle; "> <p>This is a button</p> </div> </div> </body> It's essentially 1 div, divided into 2 with text on the left hand side and a 'This is a button' label to be in the center of the right side, but I can;t figure out how to get it to center, I've tried all sorts of methods. All help/advice is appreciated.

    Read the article

  • Why Is Vertical Resolution Monitor Resolution so Often a Multiple of 360?

    - by Jason Fitzpatrick
    Stare at a list of monitor resolutions long enough and you might notice a pattern: many of the vertical resolutions, especially those of gaming or multimedia displays, are multiples of 360 (720, 1080, 1440, etc.) But why exactly is this the case? Is it arbitrary or is there something more at work? Today’s Question & Answer session comes to us courtesy of SuperUser—a subdivision of Stack Exchange, a community-driven grouping of Q&A web sites. The Question SuperUser reader Trojandestroy recently noticed something about his display interface and needs answers: YouTube recently added 1440p functionality, and for the first time I realized that all (most?) vertical resolutions are multiples of 360. Is this just because the smallest common resolution is 480×360, and it’s convenient to use multiples? (Not doubting that multiples are convenient.) And/or was that the first viewable/conveniently sized resolution, so hardware (TVs, monitors, etc) grew with 360 in mind? Taking it further, why not have a square resolution? Or something else unusual? (Assuming it’s usual enough that it’s viewable). Is it merely a pleasing-the-eye situation? So why have the display be a multiple of 360? The Answer SuperUser contributor User26129 offers us not just an answer as to why the numerical pattern exists but a history of screen design in the process: Alright, there are a couple of questions and a lot of factors here. Resolutions are a really interesting field of psychooptics meeting marketing. First of all, why are the vertical resolutions on youtube multiples of 360. This is of course just arbitrary, there is no real reason this is the case. The reason is that resolution here is not the limiting factor for Youtube videos – bandwidth is. Youtube has to re-encode every video that is uploaded a couple of times, and tries to use as little re-encoding formats/bitrates/resolutions as possible to cover all the different use cases. For low-res mobile devices they have 360×240, for higher res mobile there’s 480p, and for the computer crowd there is 360p for 2xISDN/multiuser landlines, 720p for DSL and 1080p for higher speed internet. For a while there were some other codecs than h.264, but these are slowly being phased out with h.264 having essentially ‘won’ the format war and all computers being outfitted with hardware codecs for this. Now, there is some interesting psychooptics going on as well. As I said: resolution isn’t everything. 720p with really strong compression can and will look worse than 240p at a very high bitrate. But on the other side of the spectrum: throwing more bits at a certain resolution doesn’t magically make it better beyond some point. There is an optimum here, which of course depends on both resolution and codec. In general: the optimal bitrate is actually proportional to the resolution. So the next question is: what kind of resolution steps make sense? Apparently, people need about a 2x increase in resolution to really see (and prefer) a marked difference. Anything less than that and many people will simply not bother with the higher bitrates, they’d rather use their bandwidth for other stuff. This has been researched quite a long time ago and is the big reason why we went from 720×576 (415kpix) to 1280×720 (922kpix), and then again from 1280×720 to 1920×1080 (2MP). Stuff in between is not a viable optimization target. And again, 1440P is about 3.7MP, another ~2x increase over HD. You will see a difference there. 4K is the next step after that. Next up is that magical number of 360 vertical pixels. Actually, the magic number is 120 or 128. All resolutions are some kind of multiple of 120 pixels nowadays, back in the day they used to be multiples of 128. This is something that just grew out of LCD panel industry. LCD panels use what are called line drivers, little chips that sit on the sides of your LCD screen that control how bright each subpixel is. Because historically, for reasons I don’t really know for sure, probably memory constraints, these multiple-of-128 or multiple-of-120 resolutions already existed, the industry standard line drivers became drivers with 360 line outputs (1 per subpixel). If you would tear down your 1920×1080 screen, I would be putting money on there being 16 line drivers on the top/bottom and 9 on one of the sides. Oh hey, that’s 16:9. Guess how obvious that resolution choice was back when 16:9 was ‘invented’. Then there’s the issue of aspect ratio. This is really a completely different field of psychology, but it boils down to: historically, people have believed and measured that we have a sort of wide-screen view of the world. Naturally, people believed that the most natural representation of data on a screen would be in a wide-screen view, and this is where the great anamorphic revolution of the ’60s came from when films were shot in ever wider aspect ratios. Since then, this kind of knowledge has been refined and mostly debunked. Yes, we do have a wide-angle view, but the area where we can actually see sharply – the center of our vision – is fairly round. Slightly elliptical and squashed, but not really more than about 4:3 or 3:2. So for detailed viewing, for instance for reading text on a screen, you can utilize most of your detail vision by employing an almost-square screen, a bit like the screens up to the mid-2000s. However, again this is not how marketing took it. Computers in ye olden days were used mostly for productivity and detailed work, but as they commoditized and as the computer as media consumption device evolved, people didn’t necessarily use their computer for work most of the time. They used it to watch media content: movies, television series and photos. And for that kind of viewing, you get the most ‘immersion factor’ if the screen fills as much of your vision (including your peripheral vision) as possible. Which means widescreen. But there’s more marketing still. When detail work was still an important factor, people cared about resolution. As many pixels as possible on the screen. SGI was selling almost-4K CRTs! The most optimal way to get the maximum amount of pixels out of a glass substrate is to cut it as square as possible. 1:1 or 4:3 screens have the most pixels per diagonal inch. But with displays becoming more consumery, inch-size became more important, not amount of pixels. And this is a completely different optimization target. To get the most diagonal inches out of a substrate, you want to make the screen as wide as possible. First we got 16:10, then 16:9 and there have been moderately successful panel manufacturers making 22:9 and 2:1 screens (like Philips). Even though pixel density and absolute resolution went down for a couple of years, inch-sizes went up and that’s what sold. Why buy a 19″ 1280×1024 when you can buy a 21″ 1366×768? Eh… I think that about covers all the major aspects here. There’s more of course; bandwidth limits of HDMI, DVI, DP and of course VGA played a role, and if you go back to the pre-2000s, graphics memory, in-computer bandwdith and simply the limits of commercially available RAMDACs played an important role. But for today’s considerations, this is about all you need to know. Have something to add to the explanation? Sound off in the the comments. Want to read more answers from other tech-savvy Stack Exchange users? Check out the full discussion thread here.     

    Read the article

  • Collision Detection with SAT: False Collision for Diagonal Movement Towards Vertical Tile-Walls?

    - by Macks
    Edit: Problem solved! Big thanks to Jonathan who pointed me in the right direction. Sean describes the method I used in a different thread. Also big thanks to him! :) Here is how I solved my problem: If a collision is registered by my SAT-method, only fire the collision-event on my character if there are no neighbouring solid tiles in the direction of the returned minimum translation vector. I'm developing my first tile-based 2D-game with Javascript. To learn the basics, I decided to write my own "game engine". I have successfully implemented collision detection using the separating axis theorem, but I've run into a problem that I can't quite wrap my head around. If I press the [up] and [left] arrow-keys simultaneously, my character moves diagonally towards the upper left. If he hits a horizontal wall, he'll just keep moving in x-direction. The same goes for [up] and [left] as well as downward-diagonal movements, it works as intended: http://i.stack.imgur.com/aiZjI.png Diagonal movement works fine for horizontal walls, for both left and right-movement However: this does not work for vertical walls. Instead of keeping movement in y-direction, he'll just stop as soon as he "enters" a new tile on the y-axis. So for some reason SAT thinks my character is colliding vertically with tiles from vertical walls: http://i.stack.imgur.com/XBEKR.png My character stops because he thinks that he is colliding vertically with tiles from the wall on the right. This only occurs, when: Moving into top-right direction towards the right wall Moving into top-left direction towards the left wall Bottom-right and bottom-left movement work: the character keeps moving in y-direction as intended. Is this inherited from the way SAT works or is there a problem with my implementation? What can I do to solve my problem? Oh yeah, my character is displayed as a circle but he's actually a rectangular polygon for the collision detection. Thank you very much for your help.

    Read the article

  • Windows 7 taskbar groups to use vertical menus only, not thumbnails?

    - by Justin Grant
    I frequently have 10 or more windows of the same application (e.g. Outlook, Word, IE, etc.) open at one time. Windows 7's new taskbar grouping thumbnail feature shows a preview of open windows (aka thumbnails) when you single-click on the taskbar group for that application. But when I have over 10 windows open (more thumbnails than will fit horizontally on my screen), Windows reverts to a vertical menu. This is disconcerting since I need to train myself to deal with two separate behaviors and can never anticipate what I'm going to see when I click on a taskbar group. Furthermore, I find the thumbnails more difficult to visually scan through (vs. the vertical menu) because only 1-2 words of each window's title are shown. Typically that's not enough text to disambiguate and help me find the right window. I'd like to force Windows 7's taskbar grouping to always show a vertical menu (like in XP) instead of sometimes showing thumbnail previews and sometimes showing a vertical menu. Anyone know how (whether?) this can be done? UPDATE: BTW, I'm running the RTM version (build 7600) of Windows 7. There are apparently other solutions out there which work on earlier builds, but which don't work on the RTM build.

    Read the article

  • JEditorPane scrolling to the current caret position

    - by Elliott
    I have a JEditorPane which I use to display an HTML document. the document has hyperlinks embedded in it. When a user clicks on a bookmark a position the caret to the associated place in the JeditorPane. The JeditorPane is then suppose to scroll to this position. This works mostly. But, I noticed that if the document has a lot of "break tags" (BR) tags embedded in it, the scrolling does not position the JEditorPane to right place. It's like the tags throw the callebration off. Any suggestions on what to do about this?

    Read the article

  • ASP.NET AJAX UpdatePanel problem

    - by Velika
    I'll try and be concise: 1) I have a dropdownlist with Autopostback set to TRUE 2) I have an UpdatePanel that contains a Label. 3) When the downdownlist selection is changed, I want to update the label. Problem: Focus is lost on the dropdownlist, forcing the user to click on the dropdownlist to reset focus back to the control. My "solution": In the DropDownList_SelectionChanged event, set focus back to the drop down list: dropdownlist1.focus() Problem: While this works great in IE, Firefox and Chrome change the scroll position such that the control which was assigned focus is positioned at the bottom on the visible portion of the browser window. This is often a very disorientating side effect. How can this be avoided so it works in FF as it does in IE?

    Read the article

  • CSS vertcial centering split background image not overlapping

    - by user295292
    is it possible to split 2 images vertically and when resizing the browser, it wont overlap but stay vertically centered? can the left image stay fixed so the right side of it won't cut off(overlap) this is what i have now, but when resizing the browser smaller, it pushes the left image underneath the right. rather have the images cut off on the outer sides and never overlap each other in the middle, make sense? wrapper { width:1680px; max-width:1680px; height:500px; margin: 0 auto; } left-image { width: 50%; position:absolute; left: auto; height:500px; } right-image { width: 50%; position:absolute; right: 0px; height:500px; }

    Read the article

< Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >