How to make a vertical lift or elevator in a platform game

I am creating a side scrolling platform game using the book "Flash Game University" by Gary Rosenzweig.
My protagonist has an instance of "hero".
My current issue is trying to create a lift or elevator to carry the player up or down. The lift is not covered in the book. My thoughts were that the lift constantly moved up and down at a pace determined by a timer. I cannot get my lift to move. I have created a movie clip called "lift" and made it exported for action script. I can make it act similar to a floor movie clip so that I can stand on it, but I cannot get the lift to move on the y axis.
I tried creating a new function called lift() and using a for loop to count between 0 and 100 using a variable "i" and then make my lift move up 1 unit for each loopcycle. It didn't work.
lift.y -= lift.y - 1;
Does anyone have a better solution?
Thanks,
Alex

Rob,
This worked. Here is my current code ...
var topIndex:Number = 20;
                    var bottomIndex:Number = 160;
                    var stepDistance:Number = 10;
                    var movingUp:Boolean = true;
public function createLift()
                                        box = new Object();
                                        box.mc = gamelevel.box;
public function moveMyLift():void
                                        // lift 01
                                        if (movingUp && box.mc.y > topIndex)
                                                  box.mc.y -= stepDistance;
                                        else
                                                  movingUp = false;
                                          if (!movingUp && box.mc.y < bottomIndex)
                                                  box.mc.y += stepDistance;
                                        else
                                                  movingUp = true;
                                        if (hero.mc.hitTestObject(box.mc))
                                                  hero.mc.y = box.mc.y;
My lift works correctly. It moves up and down correctly and when I jump on it I stay moving on it. There are only 3 things that don't make sense.
1. When I am on the elevator I cannot jump. If I am not on the elevator I can jump normally.
2. When I touch any portion of the elevator, my character automatically repositions itself to stand on the elevator. It seems normal, but not something that should happen in my scenario. I only want to "climb" on the elevator if I touch the "top" of the elevator.
3. If I add a second elevator, even with its own function, the timing of the elevator math appears to synch instead of work independently. Why? The two elevators synch their movement and timing. Also the first elevator stutters as the synching of the two elevators match thier movement and then moves in unison with the second elevator. Why are they not operating separately?
Here is the code for the first and second elevator:
private var box:Object;
private var box02:Object;
var topIndex:Number = 20;
var bottomIndex:Number = 160;
var stepDistance:Number = 10;
var movingUp:Boolean = true;
var topIndexLift02:Number = 1;
                    var bottomIndexLift02:Number = 100;
                    var stepDistanceLift02:Number = 4;
public function createLift()
                                        box = new Object();
                                        box.mc = gamelevel.box;
                                        box02 = new Object();
                                        box02.mc = gamelevel.box02;
public function moveMyLift():void
                                        // lift 01
                                        if (movingUp && box.mc.y > topIndex)
                                                  box.mc.y -= stepDistance;
                                        else
                                                  movingUp = false;
                                          if (!movingUp && box.mc.y < bottomIndex)
                                                  box.mc.y += stepDistance;
                                        else
                                                  movingUp = true;
                                        if (hero.mc.hitTestObject(box.mc))
                                                  hero.mc.y = box.mc.y;
                              public function moveMyLift02():void
                                        // lift02
                                        if (movingUp && box02.mc.y > topIndexLift02)
                                                  box02.mc.y -= stepDistanceLift02;
                                        else
                                                  movingUp = false;
                                          if (!movingUp && box02.mc.y < bottomIndexLift02)
                                                  box02.mc.y += stepDistanceLift02;
                                        else
                                                  movingUp = true;
                                        if (hero.mc.hitTestObject(box02.mc))
                                                  hero.mc.y = box02.mc.y;
public function gameLoop(event:Event)
                                        // get time difference
                                        if (lastTime == 0) lastTime = getTimer();
                                        var timeDiff:int = getTimer() - lastTime;
                                        lastTime += timeDiff;
                                        // only perform tasks if in play mode
                                        if (gameMode == "play")
                                                  moveCharacter(hero,timeDiff);
                                                  moveEnemies(timeDiff);
                                                  checkCollisions();
                                                  scrollWithHero();
                                                  createLift();
                                                  moveMyLift();
  moveMyLift02();
Thank you,
Alex
Message was edited by: ajdove

Similar Messages

  • How to make baseline vertical

    Hello All,
         how to make baseline vertical.
    Always baseline is horizontal i.e we can draw the text only in
    horizontal line . How to make baseline vertical . Is there any method
    in jdk1.1.8 to make baseline vertical.
    Can any one answere?
    Sharmila

    in 1.1.8, no
    AffineTransform (introduced in java1.2) allows an arbitrary transform to be applied to the origin, so it can be used to perform the task you want. However, this functionality is unavailable in <1.2 JREs.
    rob,

  • How to make a Vertical Total of a multilline item?

    Hello,
    I have a block that contains 12 numeric multiline items. I would like to make a vertical total for each item.
    I tried to make a reference item, it didn't work. i tried also to make it by doing a Sum of my item, it didn't work neither.
    Could someone give me any ideas how to figure it out?
    thanks

    You use Summarized items for this:
    -Create a non-database-block, name it e.g. BL_CONTROL, set the property "Single record" to "Yes".
    -Create a number-item in the block, set the property "Calculation Mode" to "Summary", "Summary function" to "sum", and "Summarized Block" and "Summarized item" to your block/item you want to sum up.
    -Set the property "Query all records" to "Yes" on your database-block.

  • How to  make the vertical  scrollbar  moved  automaticlly?

    Hi:
      I make a  program using BDC to create  POs.
      In my bdc recording process, i only inserted a line material item ,  but now in my program i failed  to  insert material items  over <b>7</b> because the screen only have 7 lines in default situation. how to solve this problem?   thanks inadvance!

    Hi guixin chen
    But programming for the scroll bar is never a good idea...
    Simply because thsi depends on the GUI settings on OS settings of the user.
    and you cant possibly program to consider all this.
    The best option as somebody suggested is to use teh bapi/fm.
    If u r trying to add some items to the PO in BDC, you might also have the option through the menu to add a new item. use that instead of a scroll. This will make ur BDC GUI settings independant.
    Rgds,
    Prashanth.

  • How to make a vertical calendar with ical 3.0.3/leopard?

    Hello,
    With this version of ical (3.0.3) running OS 10.5.3, I can't seem to figure out how to create and print a vertical ical calendar. Any advice?
    Thanks much.

    To do a video Podcast - You should use iMovie to create a movie and then save as a .mov file, upload to the internet and then update the RSS feed accordingly.
    Garageband can be used to create an Audio Podcast, either share to iTunes with out the podcasting track and convert to MP3. Or for an enhanced Podcast - have the podcasting track enabled and then Share to iTunes - it will go over as an AAC file.
    But GB3 is not going to do video - that is what iMovie
    Rob @ podCast411
    http://www.podcast411.com

  • How to make a vertical Power Spectrum graph?

    I need help to rotate a graph 90 degrees. My input is Scaled Data which goes into an Index Array to split the channels. The graph is okay for the selected channel but is in landscape mode and I want it to be relatively thin and vertical i.e. exchange the X&y axis.

    I may not understand exactly what you need, but I have a suggestion.
    The trick is to reformat the data and use an XY graph. They allow for ultimate control of the displayed data because they just draw lines between the x-y points in their data array. I suspect the scaled data in your VI is in a cluster. Unbundle it, autoindex the array with a for loop, bundle in a "x value", pass the array of clusters to the xy graph.

  • How to make only vertical scrollbar?

    my codes are shown as the following 2 classes:
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    import javax.swing.JScrollPane.*;
    class showConsole2{
    public static void main(String argv[])throws Throwable{
    consoleFrame csf = new consoleFrame();
    csf.show();
    class consoleFrame extends JFrame{
    public consoleFrame()throws Throwable{
    super("Console"); setSize(150, 200);
    JPanel p1, p2, p3, p4, p5, p6, content ;
    p1 = new JPanel(); p2 = new JPanel();
    p3 = new JPanel(); p4 = new JPanel();
    p5 = new JPanel(); p6 = new JPanel();
    content = new JPanel();
    JLabel l1, l2, l3, l4, l5, l6;
    l1 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
    l2 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
    l3 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
    l4 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
    l5 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
    l6 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
    p1.add(l1); p2.add(l2); p3.add(l3);
    p4.add(l4); p5.add(l5); p6.add(l6);
    content.add(p1); content.add(p2); content.add(p3);
    content.add(p4); content.add(p5); content.add(p6);
    setContentPane(content);

    Here is the code :)
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    import javax.swing.JScrollPane.*;
    class showConsole2{
    public static void main(String argv[])throws Throwable{
         consoleFrame csf = new consoleFrame();
         csf.show();
    class consoleFrame extends JFrame{
         public consoleFrame()throws Throwable
              super("Console"); setSize(150, 200);
              JPanel p1, p2, p3, p4, p5, p6,content;
              JScrollPane content1;
              content = new JPanel(new GridLayout(6,1));
              content1 = new JScrollPane(content);
              content1.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
              content1.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED);
              p1 = new JPanel(); p2 = new JPanel();
              p3 = new JPanel(); p4 = new JPanel();
              p5 = new JPanel(); p6 = new JPanel();
              JLabel l1, l2, l3, l4, l5, l6;
              l1 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
              l2 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
              l3 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
              l4 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
              l5 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
              l6 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
              p1.add(l1); p2.add(l2); p3.add(l3);
              p4.add(l4); p5.add(l5); p6.add(l6);
              content.add(p1); content.add(p2); content.add(p3);
              content.add(p4); content.add(p5); content.add(p6);
              setContentPane(content1);
    }Good Luck

  • How to make a project can be setup on windows platform by itself??thanks

    i create a project using jbuilder and i have finished it&#65292;
    how can i make it to a windows application and it can be setup on windows platform?
    it can be run as a window's service,when windows starts,it starts.

    Hi,
    After making your site SSL enabled, you might need to create
    self signed certificates which later you can distribute it for the
    subscribers of your webservice.
    The subscribers in turn need to install the certificates with
    their browser in order consume your webservices...

  • How to make an a basic attack in my text based game

    hey guys! i really need some genuine help on how to create an attack for my monsters and player. the attack should be basic: if the room contains a monster, then the monster attacks when the player goes inside the room. then the player can type a command to attack the monster. the attack should just deduct the hp of the monster. so the player can keep attacking till the monster is "dead"(this is where i remove the monster).
    anyway i tried alot in creating the attack but i failed all the time, messing my code even more. please!!!!! help!!!
    my monster class:
    public class Monster
    private int hp, stage;
    private String name;
    public Monster(String name, int stage)
    this.name = name;
    this.stage = stage;
    if(stage == 1) {
    hp = 1;
    else if(stage == 2) {
    hp = 2;
    else if(stage == 3) {
    hp = 2;
    else if(stage == 4) {
    hp = 3;
    else if(stage == 5) {
    hp = 4;
    else if(stage == 6) {
    hp = 6;
    public int monsterStage()
    return stage;
    public String getName()
    return name;
    this is where i created the monsters in my main game class:
    private Monster skeleton, sphinx, zombie, vampire, werewolf, undeadking;
    setting the monster to a room:
    skeleton = new Monster("skeleton1", 1);
    skeleton = new Monster("skeleton2", 1);
    sphinx = new Monster("sphinx1", 2);
    sphinx = new Monster("sphinx2", 2);
    sphinx = new Monster("sphinx3", 2);
    zombie = new Monster("zombie", 3);
    vampire = new Monster("vampire1", 4);
    vampire = new Monster("vampire2", 4);
    werewolf = new Monster("werewolf", 5);
    undeadking = new Monster("undeadking", 6);
    //setting the monster to a place
    bridge.addMonster("skeleton1", skeleton);
    castleDoor.addMonster("sphinx1", sphinx);
    castleChest.addMonster("zombie", zombie);
    dungeonDoor.addMonster("sphinx2", sphinx);
    castleStair.addMonster("werewolf", werewolf);
    dungeonBridge.addMonster("vampire2", vampire);
    dungeonBook.addMonster("sphinx3", sphinx);
    dungeonChest.addMonster("skeleton2", skeleton);
    throneCenter.addMonster("undeadking", undeadking);
    ps.: please help me! each room has one monster only and they are stored in hashmaps

    Here is a start of a basic text based game--it doesn't level or regen characters nor give healing or have new weapons...
    package ForumJunk;
    import java.util.Random;
    import java.util.Scanner;
    public class ForumJunk{
      private final int widthX;
      private final int heightY;
      private int myX;
      private int myY;
      private int myLevel;
      private int baseHP;
      private int myHP;
      private int myTreasure;
      private String[] myWeapon = {"fist", "open hand", "dagger", "short sword", "long sword", "b-sword", "2H sword"};
      private int[] myWeaponMaxDamage = {2, 3, 4, 6, 10, 12, 16};
      private int monsterFillFactor = 40;
      private int[][] monsterLevel = {{1, 1, 1}, {2, 2, 2}, {3, 3, 3}};
      private String[][] monsterName = {{"Skeleton", "Orac", "Kobald"}, {"Zombi", "Wolf", "Giant Rat"}, {"Bandit", "Mummy", "Ghost"}};
      private int[] monsterMaxDamage = {2, 4, 6};
      private myRoom[][] room;
      private Random rand;
      public ForumJunk(){
        widthX  = 100;
        heightY = 100;
        myLevel = 1;
        rand = new Random();
        baseHP   = 16;
        myHP     = baseHP;
        for(int i=0; i<myLevel; i++) myHP = myHP + rand.nextInt(4) + 4;
        room = new myRoom[widthX][heightY];
        for(int i=0; i<widthX; i++)for(int j=0; j<heightY; j++)room[i][j]=new myRoom();
        myX = rand.nextInt(widthX);
        myY = rand.nextInt(heightY);
        myTreasure = 0;
        fillMonster();
      public void doAttack(){
        if(!(room[myX][myY].monster != null)){
          System.out.println("Oh, it must have been my shadow; there's no monsters here \n");
          return; //no monster
        if(rand.nextBoolean()){
         doHumanAttack();
         if(room[myX][myY].monster.hp > 0) doMonsterAttack();
        }else{
          doMonsterAttack();
          doHumanAttack();
      public void doHumanAttack(){
        int weaponIndex = 0;
        if(myLevel<myWeaponMaxDamage.length) weaponIndex = myLevel;else weaponIndex = myWeaponMaxDamage.length-1;
        System.out.println("Attacking with " + myWeapon[weaponIndex] + " ...");
        int damage = myLevel * rand.nextInt(myWeaponMaxDamage[myLevel]);
        room[myX][myY].monster.hp -= damage;
        if(damage>0) System.out.println("Hit for " + damage + " damage\n");
        else System.out.println("I missed!\n");
        if(room[myX][myY].monster.hp <= 0) System.out.println("The " + room[myX][myY].monster.name  + " is dead.");
      public void doMonsterAttack(){
        System.out.println("The " + room[myX][myY].monster.name  + " is attacking...");
        int damage = rand.nextInt(monsterMaxDamage[room[myX][myY].monster.level-1]);
        myHP -= damage;
        if(damage>0) System.out.println("I've been hit for " + damage + " damage\n");
        else System.out.println("It missed me!\n");
        if(myHP<=0){
          System.out.println("Oh no, I'm dead!!!!!");
          System.exit(0);
      public void doStatus(){
        System.out.println();
        System.out.println("  Status:");
        System.out.println("    Room: " + myX + ":" + myY);
        System.out.println("      HP: " + myHP);
        System.out.println("Treasure: " + myTreasure + " gp");
        System.out.println("   Level: " + myLevel);
        System.out.println();
      public void doTreasure(){
        if(!(room[myX][myY].monster != null)){
          System.out.println("What--do you expect it just to be laying around in every room? \n");
          return; //no monster
        if(room[myX][myY].monster.hp>0){
          System.out.println("If there is any treasure that " + room[myX][myY].monster.name + " is guarding it.\n");
          return; //no monster
        myTreasure += room[myX][myY].monster.treasure;
        System.out.println("I found " + room[myX][myY].monster.treasure + " gp\n");
        room[myX][myY].monster = null;
      public void fillMonster(){
        int fill = (widthX * heightY * monsterFillFactor) / 100;
        int x = 0;
        int y = 0;
        boolean gen = false;
        for(int i=0; i<fill; i++){
          gen = true;
          while(gen){
            x = rand.nextInt(widthX);
            y = rand.nextInt(heightY);
            if(!(room[x][y].monster != null)){
              room[x][y].monster = new Monster(rand.nextInt(3)+1);
              gen = false;
      class Monster{
        int level = 0;
        int hp   = 0;
        int treasure = 0;
        String name = "";
        Monster(int level){
          this.level = level;
          hp = 1;
          for(int i = 0; i<level; i++) {
            hp += rand.nextInt(6);
            treasure += rand.nextInt(100);
          name = monsterName[level-1][rand.nextInt(3)];
      class myRoom{
        Monster monster = null;
        //what ever else you want to put in here
      public static void main(String[] args){
        String myIN = "";
        Scanner scan = new Scanner(System.in);
        ForumJunk fj = new ForumJunk();
        System.out.print("I am in room: " + fj.myX + ", " + fj.myY + " I have " + fj.myHP + " hit points and " + fj.myTreasure + " treasure ");
        if(fj.room[fj.myX][fj.myY].monster!=null){
          System.out.println("There is a  " + fj.room[fj.myX][fj.myY].monster.name + " here!");
        System.out.println("\n");
        while(!(myIN=scan.next()).equals("exit")){
          if(myIN.equals("north")){
            fj.myY -=1;
            if(fj.myY<0) fj.myY=fj.heightY-1;
          }else if(myIN.equals("south")){
            fj.myY +=1;
            if(fj.myY==fj.heightY) fj.myY=0;
          }else if(myIN.equals("west")){
            fj.myX -=1;
            if(fj.myX<0) fj.myX=fj.widthX-1;
          }else if(myIN.equals("east")){
            fj.myX +=1;
            if(fj.myX==fj.widthX) fj.myX=0;
          }else if(myIN.equals("attack")){
            fj.doAttack();
          }else if(myIN.equals("weapon")){
            System.out.println("I'll be using my " + fj.myWeapon[fj.myLevel] + " to attack\n");
          }else if(myIN.equals("treasure")){
            fj.doTreasure();
          }else if(myIN.equals("status")){
            fj.doStatus();
        System.out.print("I am in room: " + fj.myX + ", " + fj.myY + " I have " + fj.myHP + " hit points and " + fj.myTreasure + " treasure ");
        if(fj.room[fj.myX][fj.myY].monster!=null){
          System.out.print("There is a ");
          if(fj.room[fj.myX][fj.myY].monster.hp<=0) System.out.print("dead ");
          System.out.println(fj.room[fj.myX][fj.myY].monster.name + " here!");
        System.out.println("\n");
      System.out.println("Bye!");
    }

  • Can 3 vertical Radio Buttons span 3 rows in a table? AND how to make form highlight when radio butto

    I am trying to add 3 grouped vertical radio buttons where one is on each line of a 3 row table. When I group the 3 buttons it squeezes them into one row, is there a way I can have them grouped and one in each.
    Also, I would like to know how to make part of the form highlight when one of the 3 buttons is selected

    Hi,
    If I am not wrong, a table cell can hold only one component or none. In order to place the radio group to different positions vertically, you can use subforms instead of table.
    Asiye

  • How do I make text vertical in a table

    How do I make text vertical within a table using pages '09?

    You need to type the text in a Textbox, turn off text wrap, rotate that 90° using the Metric Inspector then position it over the cells you want the text vertical.
    Peter

  • Anyone know how to make vertical text in a table in keynote?

    anyone know how to make vertical text in a table in keynote?

    Just to add a bit more about this question. I have seen in other related questions that this feature (vertical text) is not available in (apparently) the whole iWork09. someone even said that it should be asked to the developers, so they include this feature in iWork10. I find this issue a bit sad. This feature has been present in msOffice since a while, and at least for me, this is quite important for my work. It is also apparently not possible to have different page orientation in the same document, meaning portrait and landscape, so one can have wide tables in a whole page, for example. If this is true, it is again sad, and I just cannot understand why such a basic feature is not available in an already 09 version. I am using only the trial version of iWork, but already in the first day I have discovered that I actually cannot do what I was used to. Again sadly I (and many others I guess) will have to stick to Office until the mac software is fully developed.

  • How to make vertical-only scrollBar?

    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    import javax.swing.JScrollPane.*;
    class showConsole2{
    public static void main(String argv[])throws Throwable{
    consoleFrame csf = new consoleFrame();
    csf.show();
    class consoleFrame extends JFrame{
    public consoleFrame()throws Throwable{
    super("Console"); setSize(150, 200);
    JPanel p1, p2, p3, p4, p5, p6, content ;
    p1 = new JPanel(); p2 = new JPanel();
    p3 = new JPanel(); p4 = new JPanel();
    p5 = new JPanel(); p6 = new JPanel();
    content = new JPanel();
    JLabel l1, l2, l3, l4, l5, l6;
    l1 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
    l2 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
    l3 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
    l4 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
    l5 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
    l6 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
    p1.add(l1); p2.add(l2); p3.add(l3);
    p4.add(l4); p5.add(l5); p6.add(l6);
    content.add(p1); content.add(p2); content.add(p3);
    content.add(p4); content.add(p5); content.add(p6);
    setContentPane(content);
    //how to modify the codes in this program to make
    //the vertical-only scrollbar?

    Try this. I believe this is what you were asking. If not, let me know...
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    import javax.swing.JScrollPane.*;
    class test
         public static void main(String argv[])
              consoleFrame csf = new consoleFrame();
              csf.setVisible(true);
    class consoleFrame extends JFrame
         public consoleFrame()
              super("Console");
              setSize(150, 200);
              JPanel p1 = new JPanel();
              JPanel p2 = new JPanel();
              JPanel p3 = new JPanel();
              JPanel p4 = new JPanel();
              JPanel p5 = new JPanel();
              JPanel p6 = new JPanel();
              JLabel l1 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
              JLabel l2 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
              JLabel l3 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
              JLabel l4 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
              JLabel l5 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
              JLabel l6 = new JLabel("aaaaaaaaaaaaaaaaaaaaaaa");
              p1.add(l1);
              p2.add(l2);
              p3.add(l3);
              p4.add(l4);
              p5.add(l5);
              p6.add(l6);
              JPanel content = new JPanel();
              content.setLayout(new GridLayout(6,1));
              content.add(p1);
              content.add(p2);
              content.add(p3);
              content.add(p4);
              content.add(p5);
              content.add(p6);
              // how to modify the codes in this program to make
              // the vertical-only scrollbar?
              JScrollPane jsp = new JScrollPane();
              jsp.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_NEVER);
              jsp.setSize(200, 100);
              JViewport view = new JViewport();
              view.setView(content);
              jsp.setViewport(view);
              this.getContentPane().add(jsp, BorderLayout.CENTER);
              this.setSize(200, 100);
    }

  • How to make a VGA monitor vertically display under an Intel GMA950?

    I have a Philips LCD Monitor (200WS8) attached to my thinkpad X41, and wanna use it vertically to display content while the internal screen of X41 have a normal display. But without success, the Philips LCD can get rotate 90 degree clockwise but poor freshrate , which seems that every operation (such as scroll in firefox) in display is really slow, and annoying font display.....
    I use this command:
    xrandr --output VGA --rotate right
    Then I test the internal screen of X41 with the command of "xrandr  --output LVDS --rotate right" and got almost the same result....
    Is it possilble to make a vertically display on an Intel card...or... this feature is depended on LCD?

    All right,I have set up my Philips LCD vertical display content with normal built in screen... need playing with xrandr & xorg.conf more then....
    one question, intel driver in linux support vertical screen?
    Last edited by andywxy (2008-11-19 15:23:01)

  • How to write text vertically in an table cell?

    Is it possible to make a table cell where the
    text would be written along a vertical base line?
    I found how to make a text box and rotate it
    vertically.
    How may I place such a text box in a table cell?
    dan    

    Hello daniel,
    if the table will not be resized or repositioned a lot, the best way to display what you want to have is to create a textbox with the styles and adjustments you need, rotate it and place it over the table cell. Be sure to make the cell big enough to pretend the text of the textbox would be inside of it. The textbox has to be a fix positioned object in the top layer.
    It's only a work-around, but the best you can achieve.
    Frank.

Maybe you are looking for

  • Intel Mac Mini networked to G4?

    Hi there! Can I connect the new Intel Mac mini to a network containing an old Mac G4 dual running OSX.3.9, and if so will I be able to access files from either computer despite the different operating systems? Also, can I install and run all my old o

  • How do i change the color of a JTable's column names

    hai, i'm very new to java and trying to customize the look of a JTable. how do i change the color of a JTable's Column names. i know its very simple, i just couldn't figure out how to do it!! thanx in advance

  • Do I have a virus/malware problem? Idiot needs help

    Hello, Received an email from 'Royal Mail Global' saying that they had failed in delivering a package and to open the attached '.zip' file. Without thinking, I opened the file- it didn't launch anything. I realise this is incredibly stupid and I am m

  • Importing from a mobile phone - specifically Nokia E65

    I can connect my E65 to my Mac Pro (it registers on the appropriate USB hub). It is neither recognised by the Operating system nor by the application (iPhoto). I recognise that the problem is due to compatibility. Has anyone found a successful soluti

  • Check sales order exits for category ZTAC

    Hi Experts I have a requirement to modify the iDOC interfaced program, In the routien which checks for the existence of a production order, I have to modify the following 1.  Inspect each item on the sales order 2. If (and only if) there is atleast o