Search Results

Search found 3394 results on 136 pages for 'vertical scrolling'.

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

  • Fix Firefox Not Scrolling with Up/Down Arrow Keys or Home/End Keys

    - by The Geek
    If you’ve encountered a problem where your Firefox installation no longer scrolls when you use the up or down arrow keys, and even the Home or End keys don’t work anymore, there’s an easy fix. When this problem happens, you’ll notice that moving the arrow keys around just moves the cursor around the page. Annoying! The problem is because you tripped the Caret Browsing feature at some point, and accidentally hit Yes. To fix this, you can just hit the F7 key again. Or, if you want to do it the about:config way, filter by accessibility.browsewithcaret and make sure it’s set to false. Remember, you can double-click on any boolean value to toggle between true and false. Similar Articles Productive Geek Tips Keyboard Ninja: Scrolling the Windows Command Prompt With Only the KeyboardShow Shortcut Keys in ScreenTips in Visual Studio 2003Show Shortcut Keys in ScreenTips in Visual Studio 2005Future Date a Post in Windows Live WriterDisable the Irritating Sticky / Filter Keys Popup Dialogs TouchFreeze Alternative in AutoHotkey The Icy Undertow Desktop Windows Home Server – Backup to LAN The Clear & Clean Desktop Use This Bookmarklet to Easily Get Albums Use AutoHotkey to Assign a Hotkey to a Specific Window Latest Software Reviews Tinyhacker Random Tips DVDFab 6 Revo Uninstaller Pro Registry Mechanic 9 for Windows PC Tools Internet Security Suite 2010 Need Help with Your Home Network? Awesome Lyrics Finder for Winamp & Windows Media Player Download Videos from Hulu Pixels invade Manhattan Convert PDF files to ePub to read on your iPad Hide Your Confidential Files Inside Images

    Read the article

  • WizMouse Enables Mouse Over Scrolling on Any Window

    - by ETC
    WizMouse is a free and lightweight Windows application that enables a simple but effective trick: the ability to scroll the contents of a window that is under your mouse cursor without shifting the focus to that window. It may not seem like much, at first glance, but the ability to scroll a window without having to click on it and shift the focus of your current window is a huge time saver. Once WizMouse is installed simply mousing over any open window and engage your scroll wheel for instant scroll with no additional click or shift in focus necessary. You’ll get so used to it you’ll forget that it wasn’t built into Windows from the start. Hit up the link below to grab a copy of WizMouse, a free and Windows only application. WizMouse [Antibody Software] Latest Features How-To Geek ETC Should You Delete Windows 7 Service Pack Backup Files to Save Space? What Can Super Mario Teach Us About Graphics Technology? Windows 7 Service Pack 1 is Released: But Should You Install It? How To Make Hundreds of Complex Photo Edits in Seconds With Photoshop Actions How to Enable User-Specific Wireless Networks in Windows 7 How to Use Google Chrome as Your Default PDF Reader (the Easy Way) WizMouse Enables Mouse Over Scrolling on Any Window Enhance GIMP’s Image Editing Power with Gimp Paint Studio Reclaim Vertical UI Space by Moving Your Tabs to the Side in Firefox Wind and Water: Puzzle Battles – An Awesome Game for Linux and Windows How Star Wars Changed the World [Infographic] Tabs Visual Manager Adds Thumbnailed Tab Switching to Chrome

    Read the article

  • Slick 2d scrolling off screen

    - by Peter
    I have something scrolling in and out of the screen. Now when it goes off screen, I want it to scroll into the screen at another location. What I do is I grab the last pixels at the screens edge using g.copyArea and then g.drawImage on the edge of the screen. And then I do a g.translate to create room for the next row which is next render cycle. My problem is that I get a single pixel row, which is not copied onto the canvas. Where as I want each row to be added and then translated, so that the image that scrolled off screen is recreated on the other side of the screen. Here is my code, maybe there is a better way of doing this, open to any suggests, cause I'm totally stuck @Override public void render(GameContainer gc, Graphics g) throws SlickException { //g.setClip(0, 0, 300, gc.getHeight()); g.translate(0, y); g.drawImage(image,0,200); g.resetTransform(); //g.clearClip(); g.copyArea(rightImage, 0, gc.getHeight() - 1); g.drawImage(rightImage, 300, 0); g.translate(0, y); y=y+3; }

    Read the article

  • Logitech G700 mouse scrollwheel is way too sensitive, how can I configure it?

    - by Snir Hassidim
    I am trying to migrate my brother to use Ubuntu. However, his Logitech G700 mouse's scroll wheel is extremely sensitive. By sensitive, I mean that, due to the fact that it uses high-resolution scrolling, every minor nudge is interpreted as a scroll attempt. I have no way to configure this in Ubuntu - I want the OS to ignore every few events from the mouse scroll wheel to make it work properly. xev in a terminal is going crazy whenever I even lay a finger on the scroll wheel. How can I fix this issue?

    Read the article

  • Smooth drag scrolling of an Isometric map - Html5

    - by user881920
    I have implemented a basic Isometric tile engine that can be explored by dragging the map with the mouse. Please see the fiddle below and drag away: http://jsfiddle.net/kHydg/14/ The code broken down is (CoffeeScript): The draw function draw = -> requestAnimFrame draw canvas.width = canvas.width for row in [0..width] for col in [0..height] xpos = (row - col) * tileHeight + width xpos += (canvas.width / 2) - (tileWidth / 2) + scrollPosition.x ypos = (row + col) * (tileHeight / 2) + height + scrollPosition.y context.drawImage(defaultTile, Math.round(xpos), Math.round(ypos), tileWidth, tileHeight) Mouse drag-scrolling control scrollPosition = x: 0 y: 0 dragHelper = active: false x: 0 y: 0 window.addEventListener 'mousedown', (e) => handleMouseDown(e) , false window.addEventListener 'mousemove', (e) => handleDrag(e) , false window.addEventListener 'mouseup', (e) => handleMouseUp(e) , false handleDrag = (e) => e.preventDefault() if dragHelper.active x = e.clientX y = e.clientY scrollPosition.x -= Math.round((dragHelper.x - x) / 28) scrollPosition.y -= Math.round((dragHelper.y - y) / 28) handleMouseUp = (e) => e.preventDefault() dragHelper.active = false handleMouseDown = (e) => e.preventDefault() x = e.clientX y = e.clientY dragHelper.active = true dragHelper.x = x dragHelper.y = y The Problem As you can see from the fiddle the dragging action is ok but not perfect. How would I change the code to make the dragging action more smooth? What I would like is the point of the map you click on to stay under the mouse point whilst you drag; the same as they have done here: http://craftyjs.com/demos/isometric/

    Read the article

  • Problem with scrolling background in one OpenGL loop

    - by GvS
    I have 960x3000 map image in png and I'm scrolling it in a loop like this (it's called in 60 FPS loop): glPushMatrix(); glBindTexture( GL_TEXTURE_2D, mapTex[iBgImg]); glBegin(GL_QUADS); double mtstart = 0.0f - fBgVPos/(double)BgSize; double mtend = mtstart + mtsize; glTexCoord2d(0.0, mtstart); glVertex2f(fBgX, TOP_MARGIN); glTexCoord2d(1.0, mtstart); glVertex2f(fBgX + MAP_WIDTH, TOP_MARGIN); glTexCoord2d(1.0, mtend); glVertex2f(fBgX + MAP_WIDTH, BOTTOM_MARGIN); glTexCoord2d(0.0, mtend); glVertex2f(fBgX, BOTTOM_MARGIN); glEnd(); glPopMatrix(); unfortunately it isn't smooth when the game is in windowed mode. However, it is smooth in full screen mode. I'm using GLFW for windows. Maybe there is something wrong with my method? Is there anything better? Or could this be hardware problem? Edit: Window is created using glfwOpenWindowHint(GLFW_WINDOW_NO_RESIZE, GL_TRUE); glfwOpenWindowHint(GLFW_REFRESH_RATE, 60); and main loop is using glfwSwapInterval(1) to ensure 60 FPS;

    Read the article

  • Ubuntu is unresponsive and scrolling is very jerky

    - by peterpipe
    I'm new to Ubuntu. I've been using 12.04LTS for over a week now. For 3 days it was great but now I'm having a number of problems. I'm using an Acer Aspire one D255 it has a 250GB HDD and a 1GB Memory. My browser is Firefox. Pages freeze occasionally and I wait for over 10 minutes and have to use the computer's 'off' button. Pages crash. On facebook some pictures don't load and I have to close down and restart a couple of times. Scrolling can sometimes be very jerky. Downloading software has become a problem and I have a 'no entry' sign in the top taskbar. I've looked at this page for some help but the words used and the explanations are not helpful to someone like me who has little knowledge of this. Please - 'Ubuntu for dummies'. I'd like to continue using Ubuntu but am close to giving up.

    Read the article

  • In facebook pictures bdon't always load properly and scrolling is very jerky

    - by peterpipe
    I'm new to Ubuntu. I've been using 12.04LTS for over a week now. For 3 days it was great but now I'm having a number of problems. I'm using an Acer Aspire one D255 it has a 250GB HDD and a 1GB Memory. My browser is Firefox. Pages freeze occasionally and I wait for over 10 minutes and have to use the computer's 'off' button. Pages crash. On facebook some pictures don't load and I have to close down and restart a couple of times. Scrolling can sometimes be very jerky. Downloading software has become a problem and I have a 'no entry' sign in the top taskbar. I've looked at this page for some help but the words used and the explanations are not helpful to someone like me who has little knowledge of this. Please - 'Ubuntu for dummies'. I'd like to continue using Ubuntu but am close to giving up.

    Read the article

  • BlackBerry - MainScreen with labels vertical scroll

    - by pajton
    I am trying to create a MainScreen with vertical scrolling. From what I've read in the documentation, MainScreen has a VerticalManager inside, so it should be possible to enable vertical scrolling only with proper construction, i.e: super(MainScreen.VERTICAL_SCROLL | MainScreen.VERTICAL_SCROLLBAR); This is not working for me, however. I am creating a screen, adding a couple of LabelFields and no scrollbar, no scrolling at all. I am testing on 8900, OS 5.0. Here is the code I use: public class ExampleScreen extends MainScreen { public ExampleScreen() { super(MainScreen.VERTICAL_SCROLL | MainScreen.VERTICAL_SCROLLBAR); create(); } private void add(String text) { add(new LabelField(text)); } private void create() { add("line 0"); add("line 1"); ... etc ... } } The question is am I doing something wrong? Is there a way to enable vertical scrolling with MainScreen or do I need to create a VerticalManager myself?

    Read the article

  • Apple Magic Mouse scrolling in Ubuntu 9.10

    - by krig
    Just received new Apple Magic Mouse and tried to install it on my computer with Ubuntu 9.10. Mouse was found as Bluetooth mouse, I entered PIN as 0000 (could not find it in user manual, so just googgled it). Now I have 2 buttons working well - left and right, but scrolling does not work. I understand that there is no driver for Magic Mouse for linux, but maybe some enthusiasts already found way to enable scrolling. Without scrolling with only 2 buttons this mouse is just like my first mouse I bought in 1997, Mitsumi as I can remember =)

    Read the article

  • Scrolling an HTML 5 page using JQuery

    - by nikolaosk
    In this post I will show you how to use JQuery to scroll through an HTML 5 page.I had to help a friend of mine to implement this functionality and I thought it would be a good idea to write a post.I will not use any JQuery scrollbar plugin,I will just use the very popular JQuery Library. Please download the library (minified version) from http://jquery.com/download.Please find here all my posts regarding JQuery.Also have a look at my posts regarding HTML 5.In order to be absolutely clear this is not (and could not be) a detailed tutorial on HTML 5. There are other great resources for that.Navigate to the excellent interactive tutorials of W3School.Another excellent resource is HTML 5 Doctor.Two very nice sites that show you what features and specifications are implemented by various browsers and their versions are http://caniuse.com/ and http://html5test.com/. At this times Chrome seems to support most of HTML 5 specifications.Another excellent way to find out if the browser supports HTML 5 and CSS 3 features is to use the Javascript lightweight library Modernizr.In this hands-on example I will be using Expression Web 4.0.This application is not a free application. You can use any HTML editor you like.You can use Visual Studio 2012 Express edition. You can download it here. Let me move on to the actual example.This is the sample HTML 5 page<!DOCTYPE html><html lang="en">  <head>    <title>Liverpool Legends</title>        <meta http-equiv="Content-Type" content="text/html;charset=utf-8" >        <link rel="stylesheet" type="text/css" href="style.css">        <script type="text/javascript" src="jquery-1.8.2.min.js"> </script>     <script type="text/javascript" src="scroll.js">     </script>       </head>  <body>    <header>        <h1>Liverpool Legends</h1>    </header>        <div id="main">        <table>        <caption>Liverpool Players</caption>        <thead>            <tr>                <th>Name</th>                <th>Photo</th>                <th>Position</th>                <th>Age</th>                <th>Scroll</th>            </tr>        </thead>        <tfoot class="footnote">            <tr>                <td colspan="4">We will add more photos soon</td>            </tr>        </tfoot>    <tbody>        <tr class="maintop">        <td>Alan Hansen</td>            <td>            <figure>            <img src="images\Alan-hansen-large.jpg" alt="Alan Hansen">            <figcaption>The best Liverpool Defender <a href="http://en.wikipedia.org/wiki/Alan_Hansen">Alan Hansen</a></figcaption>            </figure>            </td>            <td>Defender</td>            <td>57</td>            <td class="top">Middle</td>        </tr>        <tr>        <td>Graeme Souness</td>            <td>            <figure>            <img src="images\graeme-souness-large.jpg" alt="Graeme Souness">            <figcaption>Souness was the captain of the successful Liverpool team of the early 1980s <a href="http://en.wikipedia.org/wiki/Graeme_Souness">Graeme Souness</a></figcaption>            </figure>            </td>            <td>MidFielder</td>            <td>59</td>        </tr>        <tr>        <td>Ian Rush</td>            <td>            <figure>            <img src="images\ian-rush-large.jpg" alt="Ian Rush">            <figcaption>The deadliest Liverpool Striker <a href="http://it.wikipedia.org/wiki/Ian_Rush">Ian Rush</a></figcaption>            </figure>            </td>            <td>Striker</td>            <td>51</td>        </tr>        <tr class="mainmiddle">        <td>John Barnes</td>            <td>            <figure>            <img src="images\john-barnes-large.jpg" alt="John Barnes">            <figcaption>The best Liverpool Defender <a href="http://en.wikipedia.org/wiki/John_Barnes_(footballer)">John Barnes</a></figcaption>            </figure>            </td>            <td>MidFielder</td>            <td>49</td>            <td class="middle">Bottom</td>        </tr>                <tr>        <td>Kenny Dalglish</td>            <td>            <figure>            <img src="images\kenny-dalglish-large.jpg" alt="Kenny Dalglish">            <figcaption>King Kenny <a href="http://en.wikipedia.org/wiki/Kenny_Dalglish">Kenny Dalglish</a></figcaption>            </figure>            </td>            <td>Midfielder</td>            <td>61</td>        </tr>        <tr>            <td>Michael Owen</td>            <td>            <figure>            <img src="images\michael-owen-large.jpg" alt="Michael Owen">            <figcaption>Michael was Liverpool's top goal scorer from 1997–2004 <a href="http://www.michaelowen.com/">Michael Owen</a></figcaption>            </figure>            </td>            <td>Striker</td>            <td>33</td>        </tr>        <tr>            <td>Robbie Fowler</td>            <td>            <figure>            <img src="images\robbie-fowler-large.jpg" alt="Robbie Fowler">            <figcaption>Fowler scored 183 goals in total for Liverpool <a href="http://en.wikipedia.org/wiki/Robbie_Fowler">Robbie Fowler</a></figcaption>            </figure>            </td>            <td>Striker</td>            <td>38</td>        </tr>        <tr class="mainbottom">            <td>Steven Gerrard</td>            <td>            <figure>            <img src="images\steven-gerrard-large.jpg" alt="Steven Gerrard">            <figcaption>Liverpool's captain <a href="http://en.wikipedia.org/wiki/Steven_Gerrard">Steven Gerrard</a></figcaption>            </figure>            </td>            <td>Midfielder</td>            <td>32</td>            <td class="bottom">Top</td>        </tr>    </tbody></table>          </div>            <footer>        <p>All Rights Reserved</p>      </footer>     </body>  </html>  The markup is very easy to follow and understand. You do not have to type all the code,simply copy and paste it.For those that you are not familiar with HTML 5, please take a closer look at the new tags/elements introduced with HTML 5.When I view the HTML 5 page with Firefox I see the following result. I have also an external stylesheet (style.css). body{background-color:#efefef;}h1{font-size:2.3em;}table { border-collapse: collapse;font-family: Futura, Arial, sans-serif; }caption { font-size: 1.2em; margin: 1em auto; }th, td {padding: .65em; }th, thead { background: #000; color: #fff; border: 1px solid #000; }tr:nth-child(odd) { background: #ccc; }tr:nth-child(even) { background: #404040; }td { border-right: 1px solid #777; }table { border: 1px solid #777;  }.top, .middle, .bottom {    cursor: pointer;    font-size: 22px;    font-weight: bold;    text-align: center;}.footnote{text-align:center;font-family:Tahoma;color:#EB7515;}a{color:#22577a;text-decoration:none;}     a:hover {color:#125949; text-decoration:none;}  footer{background-color:#505050;width:1150px;}These are just simple CSS Rules that style the various HTML 5 tags,classes. The jQuery code that makes it all possible resides inside the scroll.js file.Make sure you type everything correctly.$(document).ready(function() {                 $('.top').click(function(){                     $('html, body').animate({                         scrollTop: $(".mainmiddle").offset().top                     },4000 );                  });                 $('.middle').click(function(){                     $('html, body').animate({                         scrollTop: $(".mainbottom").offset().top                     },4000);                  });                     $('.bottom').click(function(){                     $('html, body').animate({                         scrollTop: $(".maintop").offset().top                     },4000);                  }); });  Let me explain what I am doing here.When I click on the Middle word (  $('.top').click(function(){ ) this relates to the top class that is clicked.Then we declare the elements that we want to participate in the scrolling. In this case is html,body ( $('html, body').animate).These elements will be part of the vertical scrolling.In the next line of code we simply move (navigate) to the element (class mainmiddle that is attached to a tr element.)      scrollTop: $(".mainmiddle").offset().top  Make sure you type all the code correctly and try it for yourself. I have tested this solution will all 4-5 major browsers.Hope it helps!!!

    Read the article

  • How do you adjust the frame or vertical alignment of a UIBarButtonItem contained by a UIToolbar inst

    - by akaii
    Horizontal positioning of UIBarButtonItems is no problem, I can simply pad the space with fixed/flexible space items. However, I can't seem to adjust the toolbar item vertically. UIToolbar has no alignment property, and UIBarButtonItem has no way of setting its frame. I need to do this because we're using a mix of custom icons created using initWithImage, and standard icons created with initWithBarButtonSystemItem. The custom icons aren't being centered properly (they're offset upwards, relative to the system icons, which are centered properly), so the toolbar looks awkward.

    Read the article

  • Vertical Scroll not working, are the guides but the screen does not scroll.

    - by Leandro
    package com.lcardenas.infoberry; import net.rim.device.api.system.DeviceInfo; import net.rim.device.api.system.GPRSInfo; import net.rim.device.api.system.Memory; import net.rim.device.api.ui.MenuItem; import net.rim.device.api.ui.component.Dialog; import net.rim.device.api.ui.component.LabelField; import net.rim.device.api.ui.component.Menu; import net.rim.device.api.ui.component.SeparatorField; import net.rim.device.api.ui.container.MainScreen; import net.rim.device.api.ui.container.VerticalFieldManager; import net.rim.device.api.ui.decor.Background; import net.rim.device.api.ui.decor.BackgroundFactory; public class vtnprincipal extends MainScreen { //llamamos a la clase principal private InfoBerry padre; //variables para el menu private MenuItem mnubateria; private MenuItem mnuestado; private MenuItem mnuacerca; public vtnprincipal(InfoBerry padre) { super(); this.padre = padre; } public void incventana(){ VerticalFieldManager _ventana = new VerticalFieldManager(VerticalFieldManager.VERTICAL_SCROLL | VerticalFieldManager.VERTICAL_SCROLLBAR); double tmemoria =((DeviceInfo.getTotalFlashSize()/1024)/1024.00); double fmemoria = ((Memory.getFlashFree()/1024)/1024.00); Background cyan = BackgroundFactory.createSolidBackground(0x00E0FFFF); Background gris = BackgroundFactory.createSolidBackground(0x00DCDCDC ); //Borramos todos de la pantalla this.deleteAll(); //llamamos al menu incMenu(); //DIBUJAMOS LA VENTANA try{ LabelField title = new LabelField("Info Berry", LabelField.FIELD_HCENTER | LabelField.USE_ALL_HEIGHT ); setTitle(title); _ventana.add(new LabelField("Información del Dispositivo", LabelField.FIELD_HCENTER |LabelField.RIGHT | LabelField.USE_ALL_HEIGHT | LabelField.NON_FOCUSABLE )); _ventana.add(new SeparatorField()); _ventana.add(new SeparatorField()); txthorizontal modelo = new txthorizontal("Modelo:", DeviceInfo.getDeviceName()); modelo.setBackground(gris); _ventana.add(modelo); txthorizontal pin = new txthorizontal("PIN:" , Integer.toHexString(DeviceInfo.getDeviceId()).toUpperCase()); pin.setBackground(cyan); _ventana.add(pin); txthorizontal imeid = new txthorizontal("IMEID:" , GPRSInfo.imeiToString(GPRSInfo.getIMEI())); imeid.setBackground(gris); _ventana.add(imeid); txthorizontal version= new txthorizontal("SO Versión:" , DeviceInfo.getSoftwareVersion()); version.setBackground(cyan); _ventana.add(version); txthorizontal plataforma= new txthorizontal("SO Plataforma:" , DeviceInfo.getPlatformVersion()); plataforma.setBackground(gris); _ventana.add(plataforma); txthorizontal numero= new txthorizontal("Numero Telefonico: " , "Hay que firmar"); numero.setBackground(cyan); _ventana.add(numero); _ventana.add(new SeparatorField()); _ventana.add(new SeparatorField()); _ventana.add(new LabelField("Memoria", LabelField.FIELD_HCENTER | LabelField.USE_ALL_HEIGHT | LabelField.NON_FOCUSABLE)); _ventana.add(new SeparatorField()); txthorizontal totalm= new txthorizontal("Memoria app Total:" , mmemoria(tmemoria) + " Mb"); totalm.setBackground(gris); _ventana.add(totalm); txthorizontal disponiblem= new txthorizontal("Memoria app Disponible:" , mmemoria(fmemoria) + " Mb"); disponiblem.setBackground(cyan); _ventana.add(disponiblem); ///txthorizontal estadoram = new txthorizontal("Memoria RAM:" , mmemoria(prueba) + " Mb"); //estadoram.setBackground(gris); //add(estadoram); _ventana.add(new SeparatorField()); _ventana.add(new SeparatorField()); this.add(_ventana); }catch(Exception e){ Dialog.alert("Excepción en clase vtnprincipal: " + e.toString()); } } //DIBUJAMOS EL MENU private void incMenu() { MenuItem.separator(30); mnubateria = new MenuItem("Bateria",40, 10) { public void run() { bateria(); } }; mnuestado = new MenuItem("Estado de Red", 50, 10) { public void run() { estado(); } }; mnuacerca = new MenuItem("Acerca de..", 60, 10) { public void run() { acerca(); } }; MenuItem.separator(70); }; // public void makeMenu(Menu menu, int instance) { if (!menu.isDisplayed()) { menu.deleteAll(); menu.add(MenuItem.separator(30)); menu.add(mnubateria); menu.add(mnuestado); menu.add(mnuacerca); menu.add(MenuItem.separator(60)); } } public void bateria(){ padre.vtnbateria.incventana(); padre.pushScreen(padre.vtnbateria); } public void estado(){ padre.vtnestado.incventana(); padre.pushScreen(padre.vtnestado); } public void acerca(){ padre.vtnacerca.incventana(); padre.pushScreen(padre.vtnacerca); } public boolean onClose(){ Dialog.alert("Hasta Luego"); System.exit(0); return true; } public double mmemoria(double x) { if ( x > 0 ) return Math.floor(x * 100) / 100; else return Math.ceil(x * 100) / 100; } }

    Read the article

  • How to prevent showing outside of world game in Cocos2D-x

    - by HRZ
    I'm trying to make a tower defense game and it can zoom in/out and scrolling over my world map. How to scroll over the game and how to restrict it not to show outside of my map(black area). At below I scroll over the map by using CCCamera but I don't know how I can restrict it. CCPoint tap = touch->getLocation(); CCPoint prev_tap = touch->getPreviousLocation(); CCPoint sub_point = tap - prev_tap; float xNewPos, yNewPos; float xEyePos, yEyePos, zEyePos; float cameraPosX, cameraPosY, cameraPosZ; // First we get the current camera position. GameLayer->getCamera()->getCenterXYZ(&cameraPosX, &cameraPosY, &cameraPosZ); GameLayer->getCamera()->getEyeXYZ(&xEyePos, &yEyePos, &zEyePos); // Calculate the new position xNewPos = cameraPosX - sub_point.x; yNewPos = cameraPosY - sub_point.y; GameLayer->getCamera()->setCenterXYZ(xNewPos, yNewPos, cameraPosZ); GameLayer->getCamera()->setEyeXYZ(xNewPos, yNewPos, zEyePos); And for zooming I used such code: GameLayer->setScale(GameLayer->getScale() + 0.002); //zooming in

    Read the article

  • how to prevent showing outside of world game in cocos2dx

    - by HRZ
    Im trying to make a tower defence game and it can zoom in/out and scrolling over my world map.How to scroll over the game and how to restrict it to don't show outside of my map. At below I scroll over the map by using CCCamera but i don't know how i can restrict it. CCPoint tap = touch->getLocation(); CCPoint prev_tap = touch->getPreviousLocation(); CCPoint sub_point = tap - prev_tap; float xNewPos, yNewPos; float xEyePos, yEyePos, zEyePos; float cameraPosX, cameraPosY, cameraPosZ; // First we get the current camera position. GameLayer->getCamera()->getCenterXYZ(&cameraPosX, &cameraPosY, &cameraPosZ); GameLayer->getCamera()->getEyeXYZ(&xEyePos, &yEyePos, &zEyePos); // Calculate the new position xNewPos = cameraPosX - sub_point.x; yNewPos = cameraPosY - sub_point.y; GameLayer->getCamera()->setCenterXYZ(xNewPos, yNewPos, cameraPosZ); GameLayer->getCamera()->setEyeXYZ(xNewPos, yNewPos, zEyePos); And for zooming i used such code: GameLayer->setScale(this->getScale() + 0.002); //zooming in

    Read the article

  • iPhone vertical toggle switch

    - by nan
    I'm trying to create a vertical toggle switch control for the iPhone (along the lines of UISwitch but vertical sliding). I was wondering whether an existing control already existed or if there are any good tutorials that explain the basics of creating custom controls for the iPhone. Currently I've tried using affine transforms to create the vertical switch from a basic UIswitch, and it works except that the slider is too small compared to the slider track, thus I'm looking for information on writing custom controls. Any direction is much appreciated.

    Read the article

  • Want to have vertical scroll bar if content is more than expected in popwindow

    - by OM The Eternity
    Want to have vertical scroll bar if content is more than expected in popwindow... I have a snippet to display the popwindow on click of a button which is given below: window.open(url,'popupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=yes,copyhistory=no,width=650,height=500,screenX=150,screenY=150,top=150,left=150,overflow-x:hidden') with this, i am not able to have th vertical scrollbar if i have the more than expected content in it, How can i get the vertical scroll bar display byitself whenever needed?

    Read the article

  • Mouse wheel scrolling in less and vim using urxvt

    - by Adam Batkin
    I have started working with rxvt-unicode (aka urxvt) but found an issue with mouse-wheel scrolling, as compared to gnome-terminal and konsole. The mouse wheel works fine for going through the scrollback buffer, but it doesn't work for automatic scrolling in less/most or vim (though in vim, setting mouse=a makes it work, but in a very different way, which I don't have to do with gnome-terminal/konsole). Is there a way to make urxvt behave like gnome-terminal and konsole when in less and vim where the mouse wheel Just Works?

    Read the article

  • Vertical alignment problem in textbox in Microsoft Word 2007

    - by Surjya Narayana Padhi
    I pardon as its not a programming question at all. But if anybody can answer this it will be usefull for me. In MS word 2007 I drew a textbox and entered some text. Then I right clicked on textbox and went to format shape Then went to TextBox tab and reduced the top internal margin to 0.1 cm. But still it seems there is too much space at the top inside the textbox. I am not able to position the text exactly at the vertical middle of textbox. If I choose the auto-rezide option in format Shape, the textBox size is increases automatically but the text remains exactly at vertical and horizontal middle of textbox. but anyhow I need the textbox to be small. This is very minor but annoying problem. Can anybody help?

    Read the article

  • UIButtons in UIScrollView stop it scrolling, how to fix?

    - by Mark McFarlane
    Hi all, I have a problem with adding a set of UIButtons to a UIScrollView. With the buttons added it seems that the scroll command is not being passed to the scroll view as the buttons cover the whole surface. I've read various posts on this but still can't figure it out. I'm pretty new to iPhone programming so there's probably something obvious I've missed. I've tried things like canCancelContentTouches and delaysContentTouches to TRUE and FALSE. Here is the code I use to add the buttons to the scrollview. The scrollview was created in IB and is passed in to the function: -(void)drawCharacters:(NSMutableArray *)chars:(UIScrollView *)target_view { //NSLog(@"CLEARING PREVIOUS BUTTONS"); //clear previous buttons for parts/kanji if(target_view == viewParts){ for (UIButton *btn in parts_buttons) { [btn removeFromSuperview]; } [parts_buttons removeAllObjects]; } else if(target_view == viewKanji){ for (UIButton *btn in kanji_buttons) { [btn removeFromSuperview]; } [kanji_buttons removeAllObjects]; } //display options int chars_per_line = 9; //change this to change the number of chars displayed on each line if(target_view == viewKanji){ chars_per_line = 8; } int char_gap = 0; //change this to change the margin between chars int char_dimensions = (320/chars_per_line)-(char_gap*2); //set starting x, y coords int x = 0, y = 0; //increment y coord y += char_gap; //NSLog(@"ABOUT TO DRAW FIRST BUTTON"); for(NSMutableArray *char_arr in chars){ //increment x coord x += char_gap; //draw at x and y UIButton *myButton = [UIButton buttonWithType:UIButtonTypeCustom]; myButton.frame = CGRectMake(x, y, char_dimensions, char_dimensions); // position in the parent view and set the size of the button [myButton setTitle:[char_arr objectAtIndex:0] forState:UIControlStateNormal]; [myButton setTitleColor:[UIColor darkGrayColor] forState:UIControlStateNormal]; [myButton setTitleColor:[UIColor colorWithRed:0.8 green:0.8 blue:0.8 alpha:1.0] forState:UIControlStateDisabled]; myButton.titleLabel.font = [UIFont boldSystemFontOfSize:22]; if(target_view == viewKanji){ myButton.titleLabel.font = [UIFont boldSystemFontOfSize:30]; } // add targets and actions if(target_view == viewParts){ [myButton addTarget:self action:@selector(partSelected:) forControlEvents:UIControlEventTouchUpInside]; } else if(target_view == viewKanji){ [myButton addTarget:self action:@selector(kanjiSelected:) forControlEvents:UIControlEventTouchUpInside]; [myButton setTag:(int)[char_arr objectAtIndex:1]]; } //if the part isnt in the current list of kanji, disable and dim it if(target_view == viewParts){ if([kanji count] > 0){ [myButton setEnabled:NO]; } bool do_break = NO; for(NSMutableArray *arr in kanji){ //NSLog([NSString stringWithFormat:@"CHECKING PARTS AGAINST %d KANJI", [kanji count]]); for(NSString *str in [[arr objectAtIndex:2] componentsSeparatedByString:@" "]){ if(([myButton.titleLabel.text isEqualToString:str])){ //NSLog(@"--------------MATCH!!!-----------------"); [myButton setEnabled:YES]; for(NSString *str1 in parts_selected){ if(([myButton.titleLabel.text isEqualToString:str1])){ [myButton setEnabled:NO]; break; } } do_break = YES; break; } if(do_break) break; } if(do_break) break; } } // add to a view [target_view addSubview:myButton]; //update coords of next button x += char_dimensions+ char_gap; if (x > (320-char_dimensions)) { x = 0; y += char_dimensions + (char_gap*2); } //add button to global array to be removed from view next update if(target_view == viewParts){ [parts_buttons addObject:myButton]; } else if(target_view == viewKanji){ [kanji_buttons addObject:myButton]; } } //NSLog(@"FINISHED DRAWING ALL BUTTONS"); } Any help on this would be greatly appreciated. I just need to fix this to finish my app.

    Read the article

  • Can I stop the page from 'scrolling' back to the top when a user clicks on a tab (with Rails not Jav

    - by Jake
    Ive built a webpage with 'tabs' using rails. When a user clicks a tab, a new page loads. I want to format it so the tabs are always in the same place on the page as a user clicks them. This happens as long as the user has not scrolled down on the page. If a user has scrolled down, clicking on the tab will refresh the page and it is no longer scrolled down - which make clicking the tabs look bad. Is there a way to keep the spot on the page where the user has scrolled down, without using Javascript? If it must be done with Javascript, any suggestions? T

    Read the article

  • how to do a smooth scrolling + fade in live feed with jquery?

    - by ijjo
    i've found a lot of news ticker plugins that kinda do what i need, but not exactly. i want to do exactly what twitter.com does on their home page with the "Top Tweets". facebook also does this on their feed. basically whenever i have a new item i want all the LIs to scroll down, make room for the new LI on top, and fade it in. the newsticker plugins i've seen all scroll through a set amount of LIs, but i want to dynamically add a new one...

    Read the article

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