NEED HELP IN LABELLING A TRIANGLE _ VERTICES

PLEASE HELP ______
import java.awt.*;
import java.awt.event.*;
import java.awt.geom.*;
import java.text.NumberFormat;
import javax.swing.*;
import javax.swing.event.*;
import javax.swing.table.DefaultTableCellRenderer;
import java.lang.*;
import java.awt.event.MouseEvent;
import java.awt.event.MouseMotionListener;
import java.awt.FileDialog;
import java.io.*;
import java.awt.BorderLayout;
import java.awt.Container;
import java.awt.event.MouseEvent;
import java.awt.event.MouseMotionListener;
import javax.swing.JFrame;
public class Geometry {
    CardLayout cards;
    JPanel panel;
    public Geometry() {
        cards = new CardLayout();
        panel = new JPanel(cards);
        addCards();
        JFrame f = new JFrame("Geometry");
        f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        f.setJMenuBar(getMenuBar());
        f.getContentPane().add(panel);
        f.setSize(500,500);
        f.setLocation(0,0);
        f.setVisible(true);
        f.addMouseMotionListener(
        new MouseMotionListener() { //anonymous inner class
            //handle mouse drag event
            public void mouseMoved(MouseEvent e) {
               System.out.println("Mouse  " + e.getX() +","  + e.getY());
            public void mouseDragged(MouseEvent e) {
                System.out.println("Draggg: x=" + e.getX() + "; y=" + e.getY());
        //            public void mouseMoved(MouseEvent me) {
        //                System.out.println("Moving: x=" + me.getX() + "; y=" + me.getY());
        //        panel.addMouseMotionListener(
        //        new MouseMotionListener() { //anonymous inner class
        //            //handle mouse drag event
        //           public void mouseDragged(MouseEvent me) {
        //               setTitle("Dragging: x=" + me.getX() + "; y=" + me.getY());
        //            public void mouseMoved(MouseEvent me) {
        //                setTitle("Moving: x=" + me.getX() + "; y=" + me.getY());
    private void addCards() {
        // card one
        TriangleModel tri = new TriangleModel(175,100,175,250,325,250);
        TriangleView view  = new TriangleView(tri);
        JPanel panelOne = new JPanel(new BorderLayout());
        panelOne.add(view.getUIPanel(), "North");
        panelOne.add(view);
        panelOne.add(view.getTablePanel(), "South");
        panelOne.setName("Pythagoras's Theorem");
        panel.add("Pythagoras's Theorem", panelOne);
              view.addMouseMotionListener(
        new MouseMotionListener() { //anonymous inner class
            //handle mouse drag event
             public void mouseMoved(MouseEvent e) {
                System.out.println("Mouse at " + e.getX() +","  + e.getY());
           public void mouseDragged(MouseEvent e) {
               System.out.println("Dragging: x=" + e.getX() + "; y=" + e.getY());
        // card two
        TestModel trin = new TestModel(175,100,175,250,325,250);
        TestView viewn  = new TestView(trin);
        JPanel panelTwo = new JPanel(new BorderLayout());
        panelTwo.add(viewn.getUIPanel(), "North");
      // panelTwo.setBackground(Color.blue);
        panelTwo.setName("Similar Triangles");
        panelTwo.add(viewn);
        panelTwo.add(viewn.getTablePanel(), "South");
              viewn.addMouseMotionListener(
        new MouseMotionListener() { //anonymous inner class
            //handle mouse drag event
             public void mouseMoved(MouseEvent e) {
                System.out.println("Mouse at " + e.getX() +","  + e.getY());
           public void mouseDragged(MouseEvent e) {
               System.out.println("Dragging: x=" + e.getX() + "; y=" + e.getY());
        panel.add("Similar Triangles", panelTwo);
        JPanel panelThree = new JPanel();
        panelThree.setBackground(Color.white);
        panelThree.setName("Circle Theorem1");
        panel.add("Circle Theorem1", panelThree);
    private JMenuBar getMenuBar() {
        JMenu File = new JMenu("File");
        JSeparator separator1 = new JSeparator();
        JMenuItem Open = new JMenuItem("Open");
//         Open.addActionListener(new java.awt.event.ActionListener() {
//            public void actionPerformed(java.awt.event.ActionEvent evt) {
//                openActionPerformed(evt);
        JMenuItem Save = new JMenuItem("Save");
        JMenuItem Print = new JMenuItem("Print");
        JMenuItem Exit = new JMenuItem("Exit");
        Exit.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                ExitActionPerformed(evt);
        JMenu theorem = new JMenu("Theorem");
        ActionListener l = new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                JMenuItem item = (JMenuItem)e.getSource();
                String name = item.getActionCommand();
                cards.show(panel, name);
        Component[] c = panel.getComponents();
        for(int j = 0; j < panel.getComponentCount(); j++) {
            String name = c[j].getName();
            JMenuItem item = new JMenuItem(name);
            item.setActionCommand(name);
            item.addActionListener(l);
            theorem.add(item);
        JMenuBar menuBar = new JMenuBar();
        JMenuBar menuBar1 = new JMenuBar();
        menuBar.add(File);
        File.add(Open);
        File.add(separator1);
        File.add(Save);
        File.add(Print);       
        File.add(Exit);
        menuBar.add(theorem);
        return menuBar;
//    private void openActionPerformed(java.awt.event.ActionEvent evt) {
//        FileDialog fileDialog = new FileDialog(this, "Open...", FileDialog.LOAD);
//        fileDialog.show();
//        if (fileDialog.getFile() == null)
//            return;
//        fileName = fileDialog.getDirectory() + File.separator + fileDialog.getFile();
//        FileInputStream fis = null;
//        String str = null;
//        try {
//            fis = new FileInputStream(fileName);
//            int size = fis.available();
//            byte[] bytes = new byte [size];
//            fis.read(bytes);
//            str = new String(bytes);
//        } catch (IOException e) {
//        } finally {
//            try {
//                fis.close();
//            } catch (IOException e2) {
//        if (str != null)
//            textBox.setText(str);
    private void ExitActionPerformed(java.awt.event.ActionEvent evt) {
        // TODO add your handling code here:
        System.exit(0);
    public static void main(String[] args) {
        new Geometry();
import java.awt.*;
import java.awt.event.*;
import java.awt.geom.*;
import java.text.NumberFormat;
import javax.swing.*;
import javax.swing.event.*;
import javax.swing.table.DefaultTableCellRenderer;
public class Triangle
public Triangle()
TriangleModel tri = new TriangleModel(175,100,175,250,325,250);
TriangleView view = new TriangleView(tri);
JFrame f = new JFrame();
f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
f.getContentPane().add(view.getUIPanel(), "North");
f.getContentPane().add(view);
f.getContentPane().add(view.getTablePanel(), "South");
f.setSize(500,500);
f.setLocation(200,200);
f.setVisible(true);
import java.awt.Point;
import java.awt.Rectangle;
import java.awt.event.MouseEvent;
import javax.swing.JTable;
import javax.swing.event.MouseInputAdapter;
* TriangleControl.java
* Created on 06 February 2005, 01:19
* @author  Rahindra Naidoo
public class TriangleControl extends MouseInputAdapter
    TriangleView view;
    TriangleModel model;
    Point start;
    boolean dragging, altering;
    Rectangle lineLens;            // used for line selection
    public TriangleControl(TriangleView tv)
        view = tv;
        model = view.getModel();
        dragging = altering = false;
        lineLens = new Rectangle(0, 0, 6, 6);
    public void mousePressed(MouseEvent e)
        Point p = e.getPoint();
        lineLens.setLocation(p.x - 3, p.y - 3);
        // are we over a line
        if(model.isLineSelected(lineLens))
            start = p;
            altering = true;
        // or are we within the triangle
        else if(model.contains(p))
            start = p;
            dragging = true;
    public void mouseReleased(MouseEvent e)
        altering = false;
        dragging = false;
        view.getCentroidLabel().setText("centroid location: " +
                                         model.findCentroid());
        view.repaint();  // for the construction lines
    public void mouseDragged(MouseEvent e)
        Point p = e.getPoint();
        if(altering)
            int x = p.x - start.x;
            int y = p.y - start.y;
            model.moveSide(x, y, p);
            updateTable();
            view.repaint();
            start = p;
        else if(dragging)
            int x = p.x - start.x;
            int y = p.y - start.y;
            model.translate(x, y);
            view.repaint();
            start = p;
    private void updateTable()
        String[] lengths = model.getLengths();
        String[] squares = model.getSquares();
        String[] angles  = model.getAngles();
        JTable table = view.getTable();
        for(int j = 0; j < angles.length; j++)
            table.setValueAt(lengths[j], 1, j + 1);
            table.setValueAt(squares[j], 2, j + 1);
            table.setValueAt(angles[j],  3, j + 1);
        view.getCentroidLabel().setText("centroid location: " +
                                         model.findCentroid());
* TriangleModel.java
* Created on 06 February 2005, 01:18
import java.awt.*;
import java.awt.event.*;
import java.awt.geom.*;
import java.text.NumberFormat;
import javax.swing.*;
import javax.swing.event.*;
import javax.swing.table.DefaultTableCellRenderer;
* @author  Rahindra Naidoo
public class TriangleModel                      //  (x1, y1)
{                                         //      |\
    static final int SIDES = 3;         //      | \
    private int cx, cy;                  //      |  \
    Polygon triangle;                     //      |_ _\ (x3, y3)
    int selectedIndex;                   //  (x2, y2)
    NumberFormat nf;
    Line2D[] medians;
    Point2D centroid;
    public TriangleModel(int x1, int y1, int x2, int y2, int x3, int y3)
        int[] x = new int[] { x1, x2, x3 };
        int[] y = new int[] { y1, y2, y3 };
        triangle = new Polygon(x, y, SIDES);
        nf = NumberFormat.getNumberInstance();
        nf.setMaximumFractionDigits(1);
    public boolean contains(Point p)
        // Polygon.contains doesn't work well enough
        return (new Area(triangle)).contains(p);
    public boolean isLineSelected(Rectangle r)
        Line2D line = new Line2D.Double();
        for(int j = 0; j < SIDES; j++)
            int[] x = triangle.xpoints;
            int[] y = triangle.ypoints;
            int x1 = x[j];
            int y1 = y[j];
            int x2 = x[(j + 1) % SIDES];
            int y2 = y[(j + 1) % SIDES];
            line.setLine(x1, y1, x2, y2);
            if(line.intersects(r))
                selectedIndex = j;
                return true;
        selectedIndex = -1;
        return false;
     * Only works for right triangle with right angle at (x2, y2)
    public void moveSide(int dx, int dy, Point p)
        int[] x = triangle.xpoints;
        int[] y = triangle.ypoints;
        switch(selectedIndex)
            case 0:
                x[0] += dx;
                x[1] += dx;
                break;
            case 1:
                y[1] += dy;
                y[2] += dy;
                break;
            case 2:
                double rise  = y[2] - y[0];
                double run   = x[2] - x[0];
                double slope = rise/run;
                // rise / run == (y[2] - p.y) / (x[2] - p.x)
                x[2] = p.x + (int)((y[2] - p.y) / slope);
                // rise / run == (p.y - y[0]) / (p.x - x[0])
                y[0] = p.y - (int)((p.x - x[0]) * slope);
    public void translate(int dx, int dy)
        triangle.translate(dx, dy);
    public Polygon getTriangle()
        return triangle;
    public String findCentroid()
        int[] x = triangle.xpoints;
        int[] y = triangle.ypoints;
        // construct the medians defined as the line from
        // any vertex to the midpoint of the opposite line
        medians = new Line2D[x.length];
        for(int j = 0; j < x.length; j++)
            int next = (j + 1) % x.length;
            int last = (j + 2) % x.length;
            Point2D vertex = new Point2D.Double(x[j], y[j]);
            // get midpoint of line opposite vertex
            double dx = ((double)x[last] - x[next])/2;
            double dy = ((double)y[last] - y[next])/2;
            Point2D oppLineCenter = new Point2D.Double(x[next] + dx,
                                                       y[next] + dy);
            medians[j] = new Line2D.Double(vertex, oppLineCenter);
        // centroid is located on any median 2/3 the way from the
        // vertex (P1) to the midpoint (P2) on the opposite side
        double[] lengths = getSideLengths();
        double dx = (medians[0].getX2() - medians[0].getX1())*2/3;
        double dy = (medians[0].getY2() - medians[0].getY1())*2/3;
        double px = medians[0].getX1() + dx;
        double py = medians[0].getY1() + dy;
        //System.out.println("px = " + nf.format(px) +
        //                 "\tpy = " + nf.format(py));
        centroid = new Point2D.Double(px, py);
        return "(" + nf.format(px) + ",  " + nf.format(py) + ")";
    public String[] getAngles()
        double[] lengths = getSideLengths();
        String[] vertices = new String[lengths.length];
        for(int j = 0; j < lengths.length; j++)
            int opp  = (j + 1) % lengths.length;
            int last = (j + 2) % lengths.length;
            double top = lengths[j] * lengths[j] +
                         lengths[last] * lengths[last] -
                         lengths[opp] * lengths[opp];
            double divisor = 2 * lengths[j] * lengths[last];
            double vertex = Math.acos(top / divisor);
            vertices[j] = nf.format(Math.toDegrees(vertex));
        return vertices;
    public String[] getLengths()
        double[] lengths = getSideLengths();
        String[] lengthStrs = new String[lengths.length];
        for(int j = 0; j < lengthStrs.length; j++)
            lengthStrs[j] = nf.format(lengths[j]);
        return lengthStrs;
    public String[] getSquares()
        double[] lengths = getSideLengths();
        String[] squareStrs = new String[lengths.length];
        for(int j = 0; j < squareStrs.length; j++)
            squareStrs[j] = nf.format(lengths[j] * lengths[j]);
        return squareStrs;
    private double[] getSideLengths()
        int[] x = triangle.xpoints;
        int[] y = triangle.ypoints;
        double[] lengths = new double[SIDES];
        for(int j = 0; j < SIDES; j++)
            int next = (j + 1) % SIDES;
            lengths[j] = Point.distance(x[j], y[j], x[next], y[next]);
        return lengths;
import java.awt.*;
import java.awt.event.*;
import java.awt.geom.*;
import java.text.NumberFormat;
import javax.swing.*;
import javax.swing.event.*;
import javax.swing.table.DefaultTableCellRenderer;
* TriangleView.java
* Created on 06 February 2005, 01:21
public class TriangleView extends JPanel
    private TriangleModel model;
    private Polygon triangle;
    private JTable table;
    private JLabel centroidLabel;
    private boolean showConstruction;
    TriangleControl control;
    public TriangleView(TriangleModel model)
        this.model = model;
        triangle = model.getTriangle();
        showConstruction = false;
        control = new TriangleControl(this);
        addMouseListener(control);
        addMouseMotionListener(control);
    public void paintComponent(Graphics g)
        super.paintComponent(g);
        Graphics2D g2 = (Graphics2D)g;
        g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING,
                            RenderingHints.VALUE_ANTIALIAS_ON);
        g2.draw(triangle);
        if(model.medians == null)
            centroidLabel.setText("centroid location: " + model.findCentroid());
        // draw medians and centroid point
        if(showConstruction && !control.dragging)
            g2.setPaint(Color.red);
            for(int j = 0; j < 3; j++)
                g2.draw(model.medians[j]);
            g2.setPaint(Color.blue);
            g2.fill(new Ellipse2D.Double(model.centroid.getX() - 2,
                                         model.centroid.getY() - 2, 4, 4));
    public TriangleModel getModel()
        return model;
    public JTable getTable()
        return table;
    public JLabel getCentroidLabel()
        return centroidLabel;
    public JPanel getUIPanel()
        JCheckBox showCon = new JCheckBox("show construction");
        showCon.addActionListener(new ActionListener()
            public void actionPerformed(ActionEvent e)
                boolean state = ((JCheckBox)e.getSource()).isSelected();
                showConstruction = state;
                repaint();
        JPanel panel = new JPanel();
        panel.add(showCon);
        return panel;
    public JPanel getTablePanel()
        String[] headers = new String[] { "", "", "", "" };
        // row and column data labels
        String[] rowHeaders = {
            "sides", "lengths", "squares", "angles", "degrees"
        String[] sidesRow = { "vertical", "horizontal", "hypotenuse" };
        String[] anglesRow = { "hyp to ver", "ver to hor", "hor to hyp" };
        // collect data from model
        String[] angles  = model.getAngles();
        String[] lengths = model.getLengths();
        String[] squares = model.getSquares();
        String[][] allData = { sidesRow, lengths, squares, anglesRow, angles };
        int rows = 5;
        int cols = 4;
        Object[][] data = new Object[rows][cols];
        for(int row = 0; row < rows; row++)
            data[row][0] = rowHeaders[row];
            for(int col = 1; col < cols; col++)
                data[row][col] = allData[row][col - 1];
        table = new JTable(data, headers)
            public boolean isCellEditable(int row, int col)
                return false;
        DefaultTableCellRenderer renderer =
            (DefaultTableCellRenderer)table.getDefaultRenderer(String.class);
        renderer.setHorizontalAlignment(JLabel.CENTER);
        centroidLabel = new JLabel("centroid location:  ", JLabel.CENTER);
        Dimension d = centroidLabel.getPreferredSize();
        d.height = table.getRowHeight();
        centroidLabel.setPreferredSize(d);
        JPanel panel = new JPanel(new BorderLayout());
        panel.setBorder(BorderFactory.createTitledBorder("triangle data"));
        panel.add(table);
        panel.add(centroidLabel, "South");
        return panel;
}PLEASE HELP ME TO LABEL THE TRIANGLE AND CHANGE THE VALUES OF THE JTABLE - to SHOW ASquare b Square and C square as well as a label on the bottom of the screen to show A^2 + B^2 = C^2 ...
ThANKS

    public void paintComponent(Graphics g) {
        super.paintComponent(g);
        Graphics2D g2 = (Graphics2D)g;
        g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING,
                RenderingHints.VALUE_ANTIALIAS_ON);
        g2.drawPolygon(triangle);
        // label the triangle
        String[] lengths = model.getLengths();
        String[] squares = model.getSquares();
        String[] angles  = model.getAngles();
        int[] x = triangle.xpoints;
        int[] y = triangle.ypoints;
        for(int j = 0; j < x.length; j++) {
            Point2D vertex = new Point2D.Double(x[j], y[j]);
            int next = (j + 0) % x.length;
            int last = (j + 1) % x.length;
            double dx = ((double)x[last] - x[next])/2;
            double dy = ((double)y[last] - y[next])/2;
            Point2D center = new Point2D.Double(x[next] + dx, y[next] + dy);
            g2.drawString(angles[j],(int)vertex.getX(),(int)vertex.getY());
            g2.drawString(lengths[j],(int)center.getX(),(int)center.getY());
        g2.drawString(squares[0],100, getHeight());
        g2.drawString(" + "+squares[1],150, getHeight());
        g2.drawString(" = "+squares[2],200, getHeight());
        if(model.medians == null)
            centroidLabel.setText("centroid location: " + model.findCentroid());
        // draw medians and centroid point
        if(showConstruction && !control.dragging) {
            g2.setPaint(Color.red);
            for(int j = 0; j < 3; j++)
                g2.draw(model.medians[j]);
            g2.setPaint(Color.blue);
            g2.fill(new Ellipse2D.Double(model.centroid.getX() - 2,
                    model.centroid.getY() - 2, 4, 4));
    }

Similar Messages

  • NEED HELP PRINTING LABELS ON MY MACBOOK PRO. PLEASE!!

    HELP!  I HAVE A 6 MONTH OLD MACBOOK PRO AND AM USING THE NEWEST VERSION OF PAGES.
        I DOWNLOAD MAILING ADDRESSES FROM THE TAX OFFICE FORMATTED FOR AVERY 5160 LABELS.
        THE DOWNLOAD COMES IN AS A .RTF  (WORD RICH TEXT FORMAT).  I CAN'T OPEN THE DOWNLOAD WITH
        PAGES.  THIS REALLY *****. 
       I WILL BUY NEW SOFTWARE IF NEEDED.
        ANY SUGGESTIONS ?

    Pages 5 no longer opens .rtf. Just one of over 100 features Apple removed.
    You can open it in TextEdit and resave it as .txt or .docx
    If you can however you will be better off using Pages '09 which should be in your Applications/iWork folder.
    Peter

  • Need help with this Pascal Triangle code....

    Hey everyonr i am totally new to Java... so need your help with this code...
    the function makeRows gives me problems... main is correct ... can someone fix my makeRows... i don't see what's wrong
    public class Pascal {
      /** Return ragged array containing the first nRows rows of Pascal's
       *  triangle.
      public static int[][] makeRows(int nRows) {
            int[][] mpr  = new int[nRows+1][];
            int l=0; int r=0;
            for (int row = 0; row < nRows; row++) {
              mpr[row] = new int[row+1];  //index starts at 0
              if (row==0) {
                mpr[0][0]= 1;
                    if (row==1) {
                mpr[1][0]= 1;
                mpr[1][1]= 1;
              if (row>=2) {
                 for (int j = 0; j <= row; j++) {
                    if (j==0)               {l=0;} else {l=mpr[row-1][j-1];}
                    if (j==mpr[row].length-1) {r=0;} else{r=mpr[row-1][j];}
                    mpr[row][j] = l + r;
            return mpr;
      public static void main(String[] args) {
             if (args.length != 1) {
               System.out.println("usage: java " + Pascal.class.getName() + " N_ROWS");
               System.exit(1);
             int nRows = Integer.parseInt(args[0]);
             if (nRows > 0) {
               int[][] pascal = makeRows(nRows);
               for (int[] row : pascal) {
              for (int v : row) System.out.print(v + " ");
              System.out.println("");
         }this makeRows function should return ragged array containing the first nRows rows of Pascal's triangle
    thanks
    Edited by: magic101 on May 9, 2008 4:03 PM

    magic,
    i think corlettk meant that some people might not know what pascal's triangle is.
    also, you didnt say what was wrong with your code, just that it was wrong.
    asking smart questions is about giving as much information you can to get the
    best answer. i would throw a System.out.print between every line of your
    algorithm. i would also supply us with the values you are getting for each row.
    also, this question is asked all the time here. do a forum search.
    1
    11
    121
    1331
    14641

  • Need help with scroll effects for horizontally + vertically scrolling website

    Hi,
    I recently came across a website that uses both horizontal and vertical scrolling where 1 scroll = full browser length move to the next section (as opposed to several rotations in a continuous motion of the mouse ball like the majority of websites). Please see the example here because I'm probably not explaining this very well : A Chocolate Bar, Restaurant and Shop for Chocolates, Fondue, Gift Boxes, and More | Max Brenner (http://maxbrenner.com).
    I'm wondering if this effect is something that can be done in Muse and if so, how to do it. It's something I'm seeing more and more and almost behaves like a slideshow that can be controlled by scrolling.
    Thank you!
    Michele

    Hi Michele,
    I am afraid that this is not possible out of the box at this stage, I will recommend that you post this on the ideas section over here, Ideas for features in Adobe Muse
    You can, in the mean time, use some CSS to disable the scroll bar, preventing the partial scrolling of the page and disabling the mouse wheel scrolling as well, leaving behind only your navigation to scroll through the page.
    - Abhishek Maurya

  • URGENT HELP REQUIRED _ Creating Labels for Triangle

    Hi everyone... the code below is my application - Pythagoras Theorem.. or rather displaying it.. But i have not been able to get the Vertex of the triangle Labelled as A B C... I need to do that and change the Triangle Table data to A B C insted of Horizontal Vertical and Hypotenuise and as the triangle is stretched on screen A B And C keep moving as well ...
    Besides i need to Show this in the tabel
    - Values of A ^ 2 , B^2 and C ^2 as welll as a row showing A^2+B^2 = C^2
    the code is as follows..
    This is the main class called Geometry
    import java.awt.*;
    import java.awt.event.*;
    import java.awt.geom.*;
    import java.text.NumberFormat;
    import javax.swing.*;
    import javax.swing.event.*;
    import javax.swing.table.DefaultTableCellRenderer;
    import java.lang.*;
    import java.awt.event.MouseEvent;
    import java.awt.event.MouseMotionListener;
    import java.awt.FileDialog;
    import java.io.*;
    import java.awt.BorderLayout;
    import java.awt.Container;
    import java.awt.event.MouseEvent;
    import java.awt.event.MouseMotionListener;
    import javax.swing.JFrame;
    public class Geometry {
        CardLayout cards;
        JPanel panel;
        public Geometry() {
            cards = new CardLayout();
            panel = new JPanel(cards);
            addCards();
            JFrame f = new JFrame("Geometry");
            f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
            f.setJMenuBar(getMenuBar());
            f.getContentPane().add(panel);
            f.setSize(500,500);
            f.setLocation(0,0);
            f.setVisible(true);
            f.addMouseMotionListener(
            new MouseMotionListener() { //anonymous inner class
                //handle mouse drag event
                public void mouseMoved(MouseEvent e) {
                   System.out.println("Mouse  " + e.getX() +","  + e.getY());
                public void mouseDragged(MouseEvent e) {
                    System.out.println("Draggg: x=" + e.getX() + "; y=" + e.getY());
            //            public void mouseMoved(MouseEvent me) {
            //                System.out.println("Moving: x=" + me.getX() + "; y=" + me.getY());
            //        panel.addMouseMotionListener(
            //        new MouseMotionListener() { //anonymous inner class
            //            //handle mouse drag event
            //           public void mouseDragged(MouseEvent me) {
            //               setTitle("Dragging: x=" + me.getX() + "; y=" + me.getY());
            //            public void mouseMoved(MouseEvent me) {
            //                setTitle("Moving: x=" + me.getX() + "; y=" + me.getY());
        private void addCards() {
            // card one
            TriangleModel tri = new TriangleModel(175,100,175,250,325,250);
            TriangleView view  = new TriangleView(tri);
            JPanel panelOne = new JPanel(new BorderLayout());
            panelOne.add(view.getUIPanel(), "North");
            panelOne.add(view);
            panelOne.add(view.getTablePanel(), "South");
            panelOne.setName("Pythagoras's Theorem");
            panel.add("Pythagoras's Theorem", panelOne);
                  view.addMouseMotionListener(
            new MouseMotionListener() { //anonymous inner class
                //handle mouse drag event
                 public void mouseMoved(MouseEvent e) {
                    System.out.println("Mouse at " + e.getX() +","  + e.getY());
               public void mouseDragged(MouseEvent e) {
                   System.out.println("Dragging: x=" + e.getX() + "; y=" + e.getY());
            // card two
            TestModel trin = new TestModel(175,100,175,250,325,250);
            TestView viewn  = new TestView(trin);
            JPanel panelTwo = new JPanel(new BorderLayout());
            panelTwo.add(viewn.getUIPanel(), "North");
          // panelTwo.setBackground(Color.blue);
            panelTwo.setName("Similar Triangles");
            panelTwo.add(viewn);
            panelTwo.add(viewn.getTablePanel(), "South");
                  viewn.addMouseMotionListener(
            new MouseMotionListener() { //anonymous inner class
                //handle mouse drag event
                 public void mouseMoved(MouseEvent e) {
                    System.out.println("Mouse at " + e.getX() +","  + e.getY());
               public void mouseDragged(MouseEvent e) {
                   System.out.println("Dragging: x=" + e.getX() + "; y=" + e.getY());
            panel.add("Similar Triangles", panelTwo);
            JPanel panelThree = new JPanel();
            panelThree.setBackground(Color.white);
            panelThree.setName("Circle Theorem1");
            panel.add("Circle Theorem1", panelThree);
        private JMenuBar getMenuBar() {
            JMenu File = new JMenu("File");
            JSeparator separator1 = new JSeparator();
            JMenuItem Open = new JMenuItem("Open");
    //         Open.addActionListener(new java.awt.event.ActionListener() {
    //            public void actionPerformed(java.awt.event.ActionEvent evt) {
    //                openActionPerformed(evt);
            JMenuItem Save = new JMenuItem("Save");
            JMenuItem Print = new JMenuItem("Print");
            JMenuItem Exit = new JMenuItem("Exit");
            Exit.addActionListener(new java.awt.event.ActionListener() {
                public void actionPerformed(java.awt.event.ActionEvent evt) {
                    ExitActionPerformed(evt);
            JMenu theorem = new JMenu("Theorem");
            ActionListener l = new ActionListener() {
                public void actionPerformed(ActionEvent e) {
                    JMenuItem item = (JMenuItem)e.getSource();
                    String name = item.getActionCommand();
                    cards.show(panel, name);
            Component[] c = panel.getComponents();
            for(int j = 0; j < panel.getComponentCount(); j++) {
                String name = c[j].getName();
                JMenuItem item = new JMenuItem(name);
                item.setActionCommand(name);
                item.addActionListener(l);
                theorem.add(item);
            JMenuBar menuBar = new JMenuBar();
            JMenuBar menuBar1 = new JMenuBar();
            menuBar.add(File);
            File.add(Open);
            File.add(separator1);
            File.add(Save);
            File.add(Print);       
            File.add(Exit);
            menuBar.add(theorem);
            return menuBar;
    //    private void openActionPerformed(java.awt.event.ActionEvent evt) {
    //        FileDialog fileDialog = new FileDialog(this, "Open...", FileDialog.LOAD);
    //        fileDialog.show();
    //        if (fileDialog.getFile() == null)
    //            return;
    //        fileName = fileDialog.getDirectory() + File.separator + fileDialog.getFile();
    //        FileInputStream fis = null;
    //        String str = null;
    //        try {
    //            fis = new FileInputStream(fileName);
    //            int size = fis.available();
    //            byte[] bytes = new byte [size];
    //            fis.read(bytes);
    //            str = new String(bytes);
    //        } catch (IOException e) {
    //        } finally {
    //            try {
    //                fis.close();
    //            } catch (IOException e2) {
    //        if (str != null)
    //            textBox.setText(str);
        private void ExitActionPerformed(java.awt.event.ActionEvent evt) {
            // TODO add your handling code here:
            System.exit(0);
        public static void main(String[] args) {
            new Geometry();
    }import java.awt.*;
    import java.awt.event.*;
    import java.awt.geom.*;
    import java.text.NumberFormat;
    import javax.swing.*;
    import javax.swing.event.*;
    import javax.swing.table.DefaultTableCellRenderer;
    public class Triangle
    public Triangle()
    TriangleModel tri = new TriangleModel(175,100,175,250,325,250);
    TriangleView view = new TriangleView(tri);
    JFrame f = new JFrame();
    f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    f.getContentPane().add(view.getUIPanel(), "North");
    f.getContentPane().add(view);
    f.getContentPane().add(view.getTablePanel(), "South");
    f.setSize(500,500);
    f.setLocation(200,200);
    f.setVisible(true);
    import java.awt.Point;
    import java.awt.Rectangle;
    import java.awt.event.MouseEvent;
    import javax.swing.JTable;
    import javax.swing.event.MouseInputAdapter;
    * TriangleControl.java
    * Created on 06 February 2005, 01:19
    * @author  Rahindra Naidoo
    public class TriangleControl extends MouseInputAdapter
        TriangleView view;
        TriangleModel model;
        Point start;
        boolean dragging, altering;
        Rectangle lineLens;            // used for line selection
        public TriangleControl(TriangleView tv)
            view = tv;
            model = view.getModel();
            dragging = altering = false;
            lineLens = new Rectangle(0, 0, 6, 6);
        public void mousePressed(MouseEvent e)
            Point p = e.getPoint();
            lineLens.setLocation(p.x - 3, p.y - 3);
            // are we over a line
            if(model.isLineSelected(lineLens))
                start = p;
                altering = true;
            // or are we within the triangle
            else if(model.contains(p))
                start = p;
                dragging = true;
        public void mouseReleased(MouseEvent e)
            altering = false;
            dragging = false;
            view.getCentroidLabel().setText("centroid location: " +
                                             model.findCentroid());
            view.repaint();  // for the construction lines
        public void mouseDragged(MouseEvent e)
            Point p = e.getPoint();
            if(altering)
                int x = p.x - start.x;
                int y = p.y - start.y;
                model.moveSide(x, y, p);
                updateTable();
                view.repaint();
                start = p;
            else if(dragging)
                int x = p.x - start.x;
                int y = p.y - start.y;
                model.translate(x, y);
                view.repaint();
                start = p;
        private void updateTable()
            String[] lengths = model.getLengths();
            String[] squares = model.getSquares();
            String[] angles  = model.getAngles();
            JTable table = view.getTable();
            for(int j = 0; j < angles.length; j++)
                table.setValueAt(lengths[j], 1, j + 1);
                table.setValueAt(squares[j], 2, j + 1);
                table.setValueAt(angles[j],  3, j + 1);
            view.getCentroidLabel().setText("centroid location: " +
                                             model.findCentroid());
    * TriangleModel.java
    * Created on 06 February 2005, 01:18
    import java.awt.*;
    import java.awt.event.*;
    import java.awt.geom.*;
    import java.text.NumberFormat;
    import javax.swing.*;
    import javax.swing.event.*;
    import javax.swing.table.DefaultTableCellRenderer;
    * @author  Rahindra Naidoo
    public class TriangleModel                      //  (x1, y1)
    {                                         //      |\
        static final int SIDES = 3;         //      | \
        private int cx, cy;                  //      |  \
        Polygon triangle;                     //      |_ _\ (x3, y3)
        int selectedIndex;                   //  (x2, y2)
        NumberFormat nf;
        Line2D[] medians;
        Point2D centroid;
        public TriangleModel(int x1, int y1, int x2, int y2, int x3, int y3)
            int[] x = new int[] { x1, x2, x3 };
            int[] y = new int[] { y1, y2, y3 };
            triangle = new Polygon(x, y, SIDES);
            nf = NumberFormat.getNumberInstance();
            nf.setMaximumFractionDigits(1);
        public boolean contains(Point p)
            // Polygon.contains doesn't work well enough
            return (new Area(triangle)).contains(p);
        public boolean isLineSelected(Rectangle r)
            Line2D line = new Line2D.Double();
            for(int j = 0; j < SIDES; j++)
                int[] x = triangle.xpoints;
                int[] y = triangle.ypoints;
                int x1 = x[j];
                int y1 = y[j];
                int x2 = x[(j + 1) % SIDES];
                int y2 = y[(j + 1) % SIDES];
                line.setLine(x1, y1, x2, y2);
                if(line.intersects(r))
                    selectedIndex = j;
                    return true;
            selectedIndex = -1;
            return false;
         * Only works for right triangle with right angle at (x2, y2)
        public void moveSide(int dx, int dy, Point p)
            int[] x = triangle.xpoints;
            int[] y = triangle.ypoints;
            switch(selectedIndex)
                case 0:
                    x[0] += dx;
                    x[1] += dx;
                    break;
                case 1:
                    y[1] += dy;
                    y[2] += dy;
                    break;
                case 2:
                    double rise  = y[2] - y[0];
                    double run   = x[2] - x[0];
                    double slope = rise/run;
                    // rise / run == (y[2] - p.y) / (x[2] - p.x)
                    x[2] = p.x + (int)((y[2] - p.y) / slope);
                    // rise / run == (p.y - y[0]) / (p.x - x[0])
                    y[0] = p.y - (int)((p.x - x[0]) * slope);
        public void translate(int dx, int dy)
            triangle.translate(dx, dy);
        public Polygon getTriangle()
            return triangle;
        public String findCentroid()
            int[] x = triangle.xpoints;
            int[] y = triangle.ypoints;
            // construct the medians defined as the line from
            // any vertex to the midpoint of the opposite line
            medians = new Line2D[x.length];
            for(int j = 0; j < x.length; j++)
                int next = (j + 1) % x.length;
                int last = (j + 2) % x.length;
                Point2D vertex = new Point2D.Double(x[j], y[j]);
                // get midpoint of line opposite vertex
                double dx = ((double)x[last] - x[next])/2;
                double dy = ((double)y[last] - y[next])/2;
                Point2D oppLineCenter = new Point2D.Double(x[next] + dx,
                                                           y[next] + dy);
                medians[j] = new Line2D.Double(vertex, oppLineCenter);
            // centroid is located on any median 2/3 the way from the
            // vertex (P1) to the midpoint (P2) on the opposite side
            double[] lengths = getSideLengths();
            double dx = (medians[0].getX2() - medians[0].getX1())*2/3;
            double dy = (medians[0].getY2() - medians[0].getY1())*2/3;
            double px = medians[0].getX1() + dx;
            double py = medians[0].getY1() + dy;
            //System.out.println("px = " + nf.format(px) +
            //                 "\tpy = " + nf.format(py));
            centroid = new Point2D.Double(px, py);
            return "(" + nf.format(px) + ",  " + nf.format(py) + ")";
        public String[] getAngles()
            double[] lengths = getSideLengths();
            String[] vertices = new String[lengths.length];
            for(int j = 0; j < lengths.length; j++)
                int opp  = (j + 1) % lengths.length;
                int last = (j + 2) % lengths.length;
                double top = lengths[j] * lengths[j] +
                             lengths[last] * lengths[last] -
                             lengths[opp] * lengths[opp];
                double divisor = 2 * lengths[j] * lengths[last];
                double vertex = Math.acos(top / divisor);
                vertices[j] = nf.format(Math.toDegrees(vertex));
            return vertices;
        public String[] getLengths()
            double[] lengths = getSideLengths();
            String[] lengthStrs = new String[lengths.length];
            for(int j = 0; j < lengthStrs.length; j++)
                lengthStrs[j] = nf.format(lengths[j]);
            return lengthStrs;
        public String[] getSquares()
            double[] lengths = getSideLengths();
            String[] squareStrs = new String[lengths.length];
            for(int j = 0; j < squareStrs.length; j++)
                squareStrs[j] = nf.format(lengths[j] * lengths[j]);
            return squareStrs;
        private double[] getSideLengths()
            int[] x = triangle.xpoints;
            int[] y = triangle.ypoints;
            double[] lengths = new double[SIDES];
            for(int j = 0; j < SIDES; j++)
                int next = (j + 1) % SIDES;
                lengths[j] = Point.distance(x[j], y[j], x[next], y[next]);
            return lengths;
    import java.awt.*;
    import java.awt.event.*;
    import java.awt.geom.*;
    import java.text.NumberFormat;
    import javax.swing.*;
    import javax.swing.event.*;
    import javax.swing.table.DefaultTableCellRenderer;
    * TriangleView.java
    * Created on 06 February 2005, 01:21
    public class TriangleView extends JPanel
        private TriangleModel model;
        private Polygon triangle;
        private JTable table;
        private JLabel centroidLabel;
        private boolean showConstruction;
        TriangleControl control;
        public TriangleView(TriangleModel model)
            this.model = model;
            triangle = model.getTriangle();
            showConstruction = false;
            control = new TriangleControl(this);
            addMouseListener(control);
            addMouseMotionListener(control);
        public void paintComponent(Graphics g)
            super.paintComponent(g);
            Graphics2D g2 = (Graphics2D)g;
            g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING,
                                RenderingHints.VALUE_ANTIALIAS_ON);
            g2.draw(triangle);
            if(model.medians == null)
                centroidLabel.setText("centroid location: " + model.findCentroid());
            // draw medians and centroid point
            if(showConstruction && !control.dragging)
                g2.setPaint(Color.red);
                for(int j = 0; j < 3; j++)
                    g2.draw(model.medians[j]);
                g2.setPaint(Color.blue);
                g2.fill(new Ellipse2D.Double(model.centroid.getX() - 2,
                                             model.centroid.getY() - 2, 4, 4));
        public TriangleModel getModel()
            return model;
        public JTable getTable()
            return table;
        public JLabel getCentroidLabel()
            return centroidLabel;
        public JPanel getUIPanel()
            JCheckBox showCon = new JCheckBox("show construction");
            showCon.addActionListener(new ActionListener()
                public void actionPerformed(ActionEvent e)
                    boolean state = ((JCheckBox)e.getSource()).isSelected();
                    showConstruction = state;
                    repaint();
            JPanel panel = new JPanel();
            panel.add(showCon);
            return panel;
        public JPanel getTablePanel()
            String[] headers = new String[] { "", "", "", "" };
            // row and column data labels
            String[] rowHeaders = {
                "sides", "lengths", "squares", "angles", "degrees"
            String[] sidesRow = { "vertical", "horizontal", "hypotenuse" };
            String[] anglesRow = { "hyp to ver", "ver to hor", "hor to hyp" };
            // collect data from model
            String[] angles  = model.getAngles();
            String[] lengths = model.getLengths();
            String[] squares = model.getSquares();
            String[][] allData = { sidesRow, lengths, squares, anglesRow, angles };
            int rows = 5;
            int cols = 4;
            Object[][] data = new Object[rows][cols];
            for(int row = 0; row < rows; row++)
                data[row][0] = rowHeaders[row];
                for(int col = 1; col < cols; col++)
                    data[row][col] = allData[row][col - 1];
            table = new JTable(data, headers)
                public boolean isCellEditable(int row, int col)
                    return false;
            DefaultTableCellRenderer renderer =
                (DefaultTableCellRenderer)table.getDefaultRenderer(String.class);
            renderer.setHorizontalAlignment(JLabel.CENTER);
            centroidLabel = new JLabel("centroid location:  ", JLabel.CENTER);
            Dimension d = centroidLabel.getPreferredSize();
            d.height = table.getRowHeight();
            centroidLabel.setPreferredSize(d);
            JPanel panel = new JPanel(new BorderLayout());
            panel.setBorder(BorderFactory.createTitledBorder("triangle data"));
            panel.add(table);
            panel.add(centroidLabel, "South");
            return panel;
    }PLEASE HELP ---- Also does any one know how to draw a Triangle on a screen which can be controlled by a JSlider such that as and whenits incremented the triangle increase and vice versa... I need to prove Similarity in triangles using A Jslider that controls one triangle while the other triangle is Still on screen

    Sharan,
    The code given was part of the assignment and you are supposed to make the changes for your part right?
    Please give details of what you have done so far and not expect us to do your assignment for you. We'll be glad to help answer questions and point to the right direction, but giving us the entire assignment and saying, very nicely I might add, "Please do it for me." Just seems to make a mockery of the hours, days, and years that many of us has spent earning our degrees and learning our skills.
    Work on it and ask specific questions with examples of what you have done and you'll get a much better response.

  • I need help with printing labels.  please

    I need help with printing labels.  thanks in advance

    Welcome to Apple Support Communities.
    In Address Book, first select a name or group of names to print.
    Then File, Print, select Style, Mailing Labels, then Layout to select a specific target label (such as an Avery number), or define your own...

  • Beginner: Need Help : Label Frame

    Beginner: Need Help : Label Frame
    Hi everyone, 
    I am trying to find a way to get my menu bar working. Little info, I am a beginner in Flash just learned the essential DVD from Adobe.
    My menu bar has the following:
    (About Us) (Services) (Quality) (Projects) (Contact Us)
    Each page will have a motion shape tween and slide the page down.
    I have type in this actions :
    stop();
    import flash.events.MouseEvent;
    //---aboutus Button Timeline change---\\
    aboutus_btn.addEventListener(MouseEvent.CLICK, aboutusClick);
    function aboutusClick(event:MouseEvent):void{
    gotoAndPlay("aboutus");
    //---services Button Timeline change---\\
    services_btn.addEventListener(MouseEvent.CLICK, servicesClick);
    function servicesClick(event:MouseEvent):void{
    gotoAndPlay("services");
    //---quality Button Timeline change---\\
    quality_btn.addEventListener(MouseEvent.CLICK, qualityClick);
    function qualityClick(event:MouseEvent):void{
    gotoAndPlay("quality");
    //---projects Button Timeline change---\\
    projects_btn.addEventListener(MouseEvent.CLICK, projectsClick);
    function projectsClick(event:MouseEvent):void{
    gotoAndPlay("projects");
    //---contactus Button Timeline change---\\
    contactus_btn.addEventListener(MouseEvent.CLICK, contactusClick);
    function contactusClick(event:MouseEvent):void{
    gotoAndPlay("contactus");
    This actions only works when I click to the next labels but doesn't work when I want to click back to the previous labels. For example, if I click onto (About Us) to (Services) and (Services) to (Quality) and (Quality) to Projects and (Projects) to (Contact Us)... it all works. If I then click from (Contact Us) back to (Projects) or even any previous buttons... it does NOT work??
    Anyone? Please help!

    This is my timeline structure. The code for the action frame is in hi-lite in yellow.
    Is this clear enough?
    I also tried rewriting the action like below, but still have the same problem.
    stop();
    aboutus_btn.addEventListener(MouseEvent.CLICK, onaboutusClick, false, 0, true);
    services_btn.addEventListener(MouseEvent.CLICK, onservicesClick, false, 0, true);
    quality_btn.addEventListener(MouseEvent.CLICK, onqualityClick, false, 0, true);
    projects_btn.addEventListener(MouseEvent.CLICK, onprojectsClick, false, 0, true);
    contactus_btn.addEventListener(MouseEvent.CLICK, oncontactusClick, false, 0, true);
    function onaboutusClick(evt:MouseEvent):void {
    gotoAndPlay("aboutus");
    function onservicesClick(evt:MouseEvent):void {
    gotoAndPlay("services");
    function onqualityClick(evt:MouseEvent):void {
    gotoAndPlay("quality");
    function onprojectsClick(evt:MouseEvent):void {
    gotoAndPlay("projects");
    function oncontactusClick(evt:MouseEvent):void {
    gotoAndPlay("contactus");

  • Firefox will not update plugins labeled in red as "potentially vulnerable plugins". Need help.

    Firefox will not update three plugins appearing below the
    statement in red : " vulnerable plugins". I tried three times, and
    all I got was other pages with lots of ads. I need help. Thanks.

    Some plugins may need to be removed using the Control Panel, or Windows Explorer, because they are managed by other software or dropped in nonstandard folders. Can you list the three plugins so people can give specific advice on them?
    For the RealPlayer Browser Record Plugin you might need to update RealPlayer or use its options dialog to turn off the recording/downloading feature in order to remove this one.

  • I need help. how to make vertical drop down menu

    I need help. I want on my site to make navigation as such on this site http://www.website24.eu/einstieg/. if you can help me and explain how?

    like this http://www.jqueryrain.com/?3khGEoMY

  • Warning this is very long code but i need help to see if I am on right trac

    I have done all the following code myself and it is the buisiness layer for my application. I have tried to follow recommendations on previous posts and I would like to be told where I can clean up my code and how? This is not complete and it looks very long to me but I need help in order to be better. There are 4 button vlivks and I have not completed them all. The criteria for application is that phonebook will accept new entries if they have names surnames and phone numbers that are not longer than 10 characters for display purposes but can change this. No duplicates are allowed. No editing of a existing entry must lead to a duplicate entry either. No new entry or edit may result in a new contact having no phone numbers.
    Many thanks for your time in advance,.....
    import javax.swing.JOptionPane;
    import java.util.ArrayList;
    public class Contact
    {// Start of the Contact class
         ArrayList<ContactDetails> phoneList = new ArrayList<ContactDetails>();          // To hold all the contacts
         ArrayList<ContactDetails> searchList = new ArrayList<ContactDetails>();          // To hold all contacts that return true on search
         ArrayList<ContactDetails> list = new ArrayList<ContactDetails>();
         String newName;                                                                                // To hold the new name
         String newSurname;                                                                           // to hold the new surname
         String newHome;                                                                                // To hold the new home number if any
         String newWork;                                                                                // To hold the new work number
         String newCell;                                                                                // To hold the new cell number
         final int MAX_LENGTH = 10;
         public boolean addToPhoneList;                                                            // Sets to false if there is an invalid entry
         public boolean addToSearchList;                                                            // Sets to false if there is an invlid search
         public boolean modifyContact;                                                            // Sets to false if there is an invalid modification
         // Method to create a new contact
         public void createNew()
         {// Start of create new()
              addToPhoneList = true;                                                                 // Set boolean to true each time the method is executed
              getNewContactsName();                                                                 // Get new name
              if(addToPhoneList == false)
                   createNew();
                   return;
              getNewContactsSurname();                                                            //Get new surname
              if(addToPhoneList == false)
                   createNew();
                   return;
              String checkName = newName;                                                            //Creates copies to be used in the checkIfDuplicate method
              String checkSurname = newSurname;
              addToPhoneList = checkIfDuplicate(checkName, checkSurname);                    //Check if the entries are duplicate
              if(addToPhoneList == false)
                   createNew();
                   return;
              getNewContactsHomeNum();                                                            // Get new home number
              if(addToPhoneList == false)
                   createNew();
                   return;
              getNewContactsWorkNum();                                                            // Get new work number
              if(addToPhoneList == false)
                   createNew();
                   return;
              getNewContactsCellNum();                                                            // Get new cell number
              if(addToPhoneList == false)
                   createNew();
                   return;
              checkAtLeastOneNumEntered();                                                       // Check that at least one phone number was entered
              if(addToPhoneList == true)
                   updateListWithNew();
         }// End of createNew()
         // Method to search for an existing contact
         public void searchExisting()
         {// Start of searchExisting()
              addToSearchList = true;                                                                 // Set the boolean true
              searchList.clear();                                                                      // Clear list from any previous searches
              if(phoneList.size() > 0)                                                            // Check if any contacts are in the list
                   getExistingDetailsAndSearch();                                                  // If there are entries then continue to search
              else
                   JOptionPane.showMessageDialog(null,"There are no contacts to search for. Please use this option when you have added a contact to the list.","Error",JOptionPane.ERROR_MESSAGE);
         }// End of searchExisting()
         // Method to modify an existing contact
         public void modifyExisting()
         {// Start of modifyExisting()
              modifyContact = true;                                                                 // Set the boolean to true
              if(phoneList.size() <= 0)                                                            // Check if the phonelist is not empty
                   JOptionPane.showMessageDialog(null,"There are no contacts to modify. Please use this option when there have been contacts added to the list.","Error",JOptionPane.ERROR_MESSAGE);
              else
                   getExistingDetailsAndModify();                                                  // If phonelist not emty continue to modify method
         }// End of modifyExisting()
         //Method to delete a contact from the list
         public void deleteExisting()
         //Method to get new contacts name
         public void getNewContactsName()
              newName = JOptionPane.showInputDialog("Please enter the new contacts name or press cancel to exit without saving.");
              if(newName == null)
                   finish();
              if(newName.trim().length()<=0)
                   JOptionPane.showMessageDialog(null,"You have not entered a name. Please try again.","Error",JOptionPane.ERROR_MESSAGE);
                   addToPhoneList = false;
                   return;
              addToPhoneList = checkLengthValid(newName, "name");
         //Method to get a new contacts surname
         public void getNewContactsSurname()
              newSurname = JOptionPane.showInputDialog("Please enter the new contacts surnname or press cancel to exit without saving.");
              if(newSurname == null)
                   finish();
              addToPhoneList = checkLengthValid(newSurname, "surname");
         //Method to get a new contacts home number
         public void getNewContactsHomeNum()
              newHome = JOptionPane.showInputDialog("Please enter the new contacts home number or press cancel to exit without saving.");
              if(newHome == null)
                   finish();
              if(newHome.trim().length() > 0)
                   try
                        Long homeNum = Long.parseLong(newHome);
                   catch(Exception e)
                        JOptionPane.showMessageDialog(null,"You may only use numbers for a valid phone number. Please try again.","Error",JOptionPane.ERROR_MESSAGE);
                        addToPhoneList = false;
                        return;
              addToPhoneList = checkLengthValid(newHome, "home number");
         //Method to get a new contacst work number
         public void getNewContactsWorkNum()
              newWork = JOptionPane.showInputDialog("Please enter the new contacts work number or press cancel to exit without saving");
              if(newWork == null)
                   finish();
              if(newWork.trim().length()> 0)
                   try
                        Long workNum = Long.parseLong(newWork);
                   catch(Exception e)
                        JOptionPane.showMessageDialog(null,"You may only use numbers for a valid number. Please try again.","Error",JOptionPane.ERROR_MESSAGE);
                        addToPhoneList = false;
                        return;
              addToPhoneList = checkLengthValid(newWork, "work number");
         //Method to get a new contacts cell number
         public void getNewContactsCellNum()
              newCell = JOptionPane.showInputDialog("Please enter the new contacts cell number or press cancel to exit without saving");
              if(newCell == null)
                   finish();
              if(newCell.trim().length() > 0)
                   try
                        Long cellNum = Long.parseLong(newCell);
                   catch(Exception e)
                        JOptionPane.showMessageDialog(null,"You may only use numbers for a valid number. Please try again.","Error",JOptionPane.ERROR_MESSAGE);
                        addToPhoneList = false;
                        return;
              addToPhoneList = checkLengthValid(newCell, "cell number");
         //Method to get the details for an existing contact
         public void getExistingDetailsAndSearch()
              String existingName = getExistingName("search for");
              if(existingName == null)
                   addToSearchList = false;
                   return;
              if(existingName.length()<=0)
                   JOptionPane.showMessageDialog(null,"You have not entered a name please try again","Error",JOptionPane.ERROR_MESSAGE);
                   addToSearchList = false;
                   searchExisting();
              String existingSurname = getExistingSurname();
                   if(existingSurname == null)
                        return;
              if(addToSearchList == true)
                   searchAndAddIfFound(existingName, existingSurname);
         //Method to get existing details and modify contact
         public void getExistingDetailsAndModify()
              String existingName = getExistingName("modify");
              if(existingName == null)
                   modifyContact = false;
                   return;
              if(existingName.length()<=0)
                   JOptionPane.showMessageDialog(null,"You have not entered a name please try again","Error",JOptionPane.ERROR_MESSAGE);
                   modifyContact = false;
                   modifyExisting();
              String existingSurname = getExistingSurname();
                   if(existingSurname == null)
                        return;
              if(modifyContact == true)
                   getContactBySearch(existingName.trim().toUpperCase(), existingSurname.trim().toUpperCase());
         //Method to get the contact from list and modify details
         public void getContactBySearch(String currentName, String currentSurname)
              int count = 0;
              int numFound = 0;
              for(ContactDetails cd: phoneList)
                   cd = phoneList.get(count);
                   if((cd.name.equals(currentName))&&(cd.surname.equals(currentSurname)))
                        numFound ++;
                        changeDetails(cd);
                   count ++;
              if(numFound <= 0)
                   JOptionPane.showMessageDialog(null,"No contacts matching the name and surname you entered found. Press the modify button to try again.","Information",JOptionPane.INFORMATION_MESSAGE);
         //Method to get existing contacts name
         public String getExistingName(String whatWasClicked)
              String name = JOptionPane.showInputDialog("Please enter the contacts name that you wish to "+whatWasClicked);
              return name;
         //Method to get an existing contacts surname
         public String getExistingSurname()
              String surname = JOptionPane.showInputDialog("Please enter the contacts surname.");
              return surname;
         //Method to change the details of contact
         public void changeDetails(ContactDetails conToChange)
              String currentName = conToChange.name;
              String currentSurname = conToChange.surname;
              String currentHome = conToChange.home;
              String currentWork = conToChange.work;
              String currentCell = conToChange.cell;
              String newNameForContact = getNewModName(currentName);
              if(modifyContact == false)
                   modifyExisting();
                   return;
              String newSurnameForContact = getNewModSurname(currentSurname);
              if(modifyContact == false)
                   modifyExisting();
                   return;
              String newHomeForContact = getNewModHome(currentHome);
              if(modifyContact == false)
                   modifyExisting();
                   return;
              String newWorkForContact = getNewModWork(currentWork);
              if(modifyContact == false)
                   modifyExisting();
                   return;
              String newCellForContact = getNewModCell(currentCell);
              if(modifyContact == false)
                   modifyExisting();
                   return;
              if(modifyContact == true)
                   conToChange.name = newNameForContact;
         //Method to get the modified name
         public String getNewModName(String currentName)
              String newModifiedName = JOptionPane.showInputDialog("Please enter the new name for contact or press cancel to keep it as is.");
              if(newModifiedName == null)
                   return currentName;
              if(newModifiedName.trim().length() <= 0)
                   JOptionPane.showMessageDialog(null,"You may not replace the existing name with a blank name. Please try again.","Error",JOptionPane.ERROR_MESSAGE);
                   modifyContact = false;
                   return currentName;
              modifyContact = checkLengthValid(newModifiedName, "modified name");
              return newModifiedName;
         //Method to get the modified surname
         public String getNewModSurname(String currentSurname)
              String newModifiedSurname = JOptionPane.showInputDialog("Please enter the new surname for the contact or press cancel to keep it as is.");
              if(newModifiedSurname == null)
                   return currentSurname;
              modifyContact = checkLengthValid(newModifiedSurname, "modified surname");
              if(modifyContact == false)
                   JOptionPane.showMessageDialog(null,"Surname not changed.","Information",JOptionPane.INFORMATION_MESSAGE);
                   return currentSurname;
              modifyContact = checkLengthValid(newModifiedSurname, "modified surname");
              return newModifiedSurname;
         //Method to search and update the list with a succesfull search
         private void searchAndAddIfFound(String name, String surname)
              int count = 0;
              int numFound = 0;
              for(ContactDetails cd: phoneList)
                   cd = phoneList.get(count);
                   if(cd.name.equals(name.trim().toUpperCase()))
                        numFound ++;
                        searchList.add(cd);
                   count ++;
              if(numFound <= 0)
                   JOptionPane.showMessageDialog(null,"No contacts were found matching the dat you entered.","Information",JOptionPane.INFORMATION_MESSAGE);
              else
                   list.clear();
                   list.addAll(searchList);
         //Method that check all entries are a valid logical length
         //Method is based on assumption that a normal name, surname, and phone numbers are not longer than 10 characters long.
         //IF This method is changed please change the layout in the GUI as this is also set to fit with the layout that gives a neat //apperance
         private boolean checkLengthValid(String detailEntered, String whatWasEntered)
              boolean validLength = true;
              if(detailEntered.trim().length() >= MAX_LENGTH)
                   JOptionPane.showMessageDialog(null,"The " +whatWasEntered+" you entered is too long. Please try again and use a "+whatWasEntered+" that is less than "+MAX_LENGTH+" characters long.","Error",JOptionPane.ERROR_MESSAGE);
                   validLength = false;
              return validLength;
         private void finish()
              System.exit(0);
         //Method to update the list with a new entry
         private void updateListWithNew()
              try
                   ContactDetails cd = new ContactDetails();
                   cd.name = newName.trim().toUpperCase();
                   cd.surname = newSurname.trim().toUpperCase();
                   cd.home = newHome.trim();
                   cd.work = newWork.trim();
                   cd.cell = newCell.trim();
                   phoneList.add(cd);
                   JOptionPane.showMessageDialog(null,"Contact succesfully entered. To save this change press exit to save or use the save option in the toolbar menu.","Information",JOptionPane.INFORMATION_MESSAGE);
              catch(Exception e)
                   JOptionPane.showMessageDialog(null,"Failed to add contact to list. If problem persists please contact the software developer.","Error",JOptionPane.ERROR_MESSAGE);
              list.clear();
              list.addAll(phoneList);
         //Method to check for duplicate
         public boolean  checkIfDuplicate(String nameToCheck, String surnameToCheck)
              int count = 0;
              boolean valid = true;
              for(ContactDetails cd : phoneList)
                   cd = phoneList.get(count);
                   if(((nameToCheck.trim().toUpperCase()).equals(cd.name))&&((surnameToCheck.trim().toUpperCase()).equals(cd.surname)))
                        JOptionPane.showMessageDialog(null,"You may not enter a duplicate contact. Please try again and change the name and surname.","Error",JOptionPane.ERROR_MESSAGE);
                        valid = false;
                        break;
                   count ++;
              return valid;
         //Method to check that at least one phone number exists for contact
         public void checkAtLeastOneNumEntered()
              if((newHome.trim().length()<=0)&&(newWork.trim().length()<=0)&&(newCell.trim().length()<=0))
                   JOptionPane.showMessageDialog(null,"You have not entered any phone number at all. You must enter at least one phone number for a new contact.","Error",JOptionPane.ERROR_MESSAGE);
                   addToPhoneList = false;
         //Method that returns the list to the GUI
         public ArrayList<ContactDetails> getList()
              return list;
    }

    Should I start over from scratch? Can I get help with links to tutorials on following? How to create a java CRUD application (google not useful) and how to layer in java(google not useful)
    This is my pres layer as is is this wrong too?
         Filename:     ContactsListInterface.java
         Date:           16 March 2008
         Programmer:     Yucca Nel
         Purpose:     Provides a GUI for entering names and contact numbers into a telephone directory.
                        Also allows options for searching for a specific name and deleting of data from the record
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    import javax.swing.text.*;
    import java.io.*;
    import java.util.*;
    import java.text.*;
    public class Phonebook1 extends JFrame implements ActionListener
    { //start of class
         // construct fields, buttons, labels,text boxes, ArrayLists etc
         JTextPane displayPane = new JTextPane();
         JLabel listOfContacts = new JLabel("List Of Contacts");               // creates a label for the scrollpane
         JButton createButton = new JButton("Create");
         JButton searchButton = new JButton("Search");
         JButton modifyButton = new JButton("Modify");
         JButton deleteButton = new JButton("Delete");
         Contact c = new Contact();
         ArrayList<ContactDetails> contactList = c.getList();
         // create an instance of the ContactsListInterface
         public Phonebook1()
         { // start of cli()
              super("Phonebook Interface");
         } // end of cli()
         public JMenuBar createMenuBar()
         { // start of the createMenuBar()
              // construct and populate a menu bar
              JMenuBar mnuBar = new JMenuBar();                              // creates a menu bar
              setJMenuBar(mnuBar);
              JMenu mnuFile = new JMenu("File",true);                         // creates a file menu in the menu bar which is visible
                   mnuFile.setMnemonic(KeyEvent.VK_F);
                   mnuFile.setDisplayedMnemonicIndex(0);
                   mnuFile.setToolTipText("File Options");
                   mnuBar.add(mnuFile);
              JMenuItem mnuFileExit = new JMenuItem("Save And Exit");     // creates an exit option in the file menu
                   mnuFileExit.setMnemonic(KeyEvent.VK_X);
                   mnuFileExit.setDisplayedMnemonicIndex(1);
                   mnuFileExit.setToolTipText("Close Application");
                   mnuFile.add(mnuFileExit);
                   mnuFileExit.setActionCommand("Exit");
                   mnuFileExit.addActionListener(this);
              JMenu mnuEdit = new JMenu("Edit",true);                         // creates a menu for editing options
                   mnuEdit.setMnemonic(KeyEvent.VK_E);
                   mnuEdit.setDisplayedMnemonicIndex(0);
                   mnuEdit.setToolTipText("Edit Options");
                   mnuBar.add(mnuEdit);
              JMenu mnuEditSort = new JMenu("Sort",true);                    // creates an option for sorting entries
                   mnuEditSort.setMnemonic(KeyEvent.VK_S);
                   mnuEditSort.setDisplayedMnemonicIndex(0);
                   mnuEdit.add(mnuEditSort);
              JMenuItem mnuEditSortByName = new JMenuItem("Sort By Name");          // to sort entries by name
                   mnuEditSortByName.setMnemonic(KeyEvent.VK_N);
                   mnuEditSortByName.setDisplayedMnemonicIndex(8);
                   mnuEditSortByName.setToolTipText("Sort entries by first name");
                   mnuEditSortByName.setActionCommand("Name");
                   mnuEditSortByName.addActionListener(this);
                   mnuEditSort.add(mnuEditSortByName);
              JMenuItem mnuEditSortBySurname = new JMenuItem("Sort By Surname");     // to sort entries by surname
                   mnuEditSortBySurname.setMnemonic(KeyEvent.VK_R);
                   mnuEditSortBySurname.setDisplayedMnemonicIndex(10);
                   mnuEditSortBySurname.setToolTipText("Sort entries by surname");
                   mnuEditSortBySurname.setActionCommand("Surname");
                   mnuEditSortBySurname.addActionListener(this);
                   mnuEditSort.add(mnuEditSortBySurname);
              JMenu mnuHelp = new JMenu("Help",true);                                        // creates a menu for help options
                   mnuHelp.setMnemonic(KeyEvent.VK_H);
                   mnuHelp.setDisplayedMnemonicIndex(0);
                   mnuHelp.setToolTipText("Help options");
                   mnuBar.add(mnuHelp);
              JMenuItem mnuHelpHelp = new JMenuItem("Help");                              // creates a help option for help topic
                   mnuHelpHelp.setMnemonic(KeyEvent.VK_P);
                   mnuHelpHelp.setDisplayedMnemonicIndex(3);
                   mnuHelpHelp.setToolTipText("Help Topic");
                   mnuHelpHelp.setActionCommand("Help");
                   mnuHelpHelp.addActionListener(this);
                   mnuHelp.add(mnuHelpHelp);
              JMenuItem mnuHelpAbout = new JMenuItem("About");                         // creates a about option for info about api
                   mnuHelpAbout.setMnemonic(KeyEvent.VK_T);
                   mnuHelpAbout.setDisplayedMnemonicIndex(4);
                   mnuHelpAbout.setToolTipText("About this program");
                   mnuHelpAbout.setActionCommand("About");
                   mnuHelpAbout.addActionListener(this);
                   mnuHelp.add(mnuHelpAbout);
              return mnuBar;
         } // end of the createMenuBar()
         // create the content pane
         public Container createContentPane()
         { // start of createContentPane()
              //construct and populate panels and content pane
              JPanel labelPanel = new JPanel(); // panel is only used to put the label for the textpane in
                   labelPanel.setLayout(new FlowLayout());
                   labelPanel.add(listOfContacts);
              JPanel displayPanel = new JPanel();// panel is used to display all the contacts and thier numbers
                   setTabsAndStyles(displayPane);
                   displayPane = addTextToTextPane();
                   displayPane.setEditable(false);
              JScrollPane scrollPane = new JScrollPane(displayPane);
                   scrollPane.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_ALWAYS); // pane is scrollable vertically
                   scrollPane.setWheelScrollingEnabled(true);// pane is scrollable by use of the mouse wheel
                   scrollPane.setPreferredSize(new Dimension(400,320));
              displayPanel.add(scrollPane);
              JPanel workPanel = new JPanel();// panel is used to enter, edit and delete data
                   workPanel.setLayout(new FlowLayout());
                   workPanel.add(createButton);
                        createButton.setToolTipText("Create a new entry");
                        createButton.addActionListener(this);
                   workPanel.add(searchButton);
                        searchButton.setToolTipText("Search for an entry by name number or surname");
                        searchButton.addActionListener(this);
                   workPanel.add(modifyButton);
                        modifyButton.setToolTipText("Modify an existing entry");
                        modifyButton.addActionListener(this);
                   workPanel.add(deleteButton);
                        deleteButton.setToolTipText("Delete an existing entry");
                        deleteButton.addActionListener(this);
              labelPanel.setBackground(Color.red);
              displayPanel.setBackground(Color.red);
              workPanel.setBackground(Color.red);
              // create container and set attributes
              Container c = getContentPane();
                   c.setLayout(new BorderLayout(30,30));
                   c.add(labelPanel,BorderLayout.NORTH);
                   c.add(displayPanel,BorderLayout.CENTER);
                   c.add(workPanel,BorderLayout.SOUTH);
                   c.setBackground(Color.red);
              // add a listener for the window closing and save
              addWindowListener(
                   new WindowAdapter()
                        public void windowClosing(WindowEvent e)
                             int answer = JOptionPane.showConfirmDialog(null,"Are you sure you would like to save all changes and exit?","File submission",JOptionPane.YES_NO_OPTION);
                             if(answer == JOptionPane.YES_OPTION)
                                  System.exit(0);
              return c;
         } // end of createContentPane()
         protected void setTabsAndStyles(JTextPane displayPane)
         { // Start of setTabsAndStyles()
              // set Font style
              Style fontStyle = StyleContext.getDefaultStyleContext().getStyle(StyleContext.DEFAULT_STYLE);
              Style regular = displayPane.addStyle("regular", fontStyle);
              StyleConstants.setFontFamily(fontStyle, "SansSerif");
              Style s = displayPane.addStyle("bold", regular);
              StyleConstants.setBold(s,true);
         } // End of setTabsAndStyles()
         public JTextPane addTextToTextPane()
         { // start of addTextToTextPane()
              int numberOfEntries = contactList.size();
              int count = 0;
              Document doc = displayPane.getDocument();
              try
              { // start of tryblock
                   // clear previous text
                   doc.remove(0,doc.getLength());
                   // insert titles of columns
                   doc.insertString(0,"NAME\tSURNAME\tHOME NO\tWORK NO\tCELL NO\n",displayPane.getStyle("bold"));
                   for(ContactDetails cd : contactList)
                        cd = contactList.get(count);
                        doc.insertString(doc.getLength(),cd.name+"\t"+cd.surname+"\t"+cd.home+"\t"+cd.work+"\t"+cd.cell+"\n",displayPane.getStyle("regular"));
                        count ++;
              } // end of try block
              catch(BadLocationException ble)
              { // start of ble exception handler
                   System.err.println("Could not insert text.");
              } // end of ble exception handler
              return displayPane;
         } // end of addTextToTextPane()
         // code to process user clicks
         public void actionPerformed(ActionEvent e)
         { // start of actionPerformed()
              String arg = e.getActionCommand();
              // user clicks create button
              if(arg.equals("Create"))
                   c.createNew();                                                  // method to create a new Contact
                   addTextToTextPane();
              if(arg.equals("Search"))
                   c.searchExisting();                                             // method to search for an existing entry
                   addTextToTextPane();
              if(arg.equals("Modify"))
                   c.modifyExisting();                                             // method to modify contact
                   addTextToTextPane();
              if(arg.equals("Delete"))
                   c.deleteExisting();
                   addTextToTextPane();
              if(arg.equals("Exit"))
         } // end of actionPerformed()
         // method to create a new contact
         public static void main(String[] args)
         { // start of main()
              // Set look and feel of interface
              try
              { // start of try block
                   UIManager.setLookAndFeel("com.sun.java.swing.plaf.windows.WindowsLookAndFeel");
              } // end of try block
              catch(Exception e)
              { // start of catch block
                   JOptionPane.showMessageDialog(null,"There was an error in setting the look and feel of this application","Error",JOptionPane.INFORMATION_MESSAGE);
              } // end  of catch block
              Phonebook1 pb = new Phonebook1();
              pb.setDefaultCloseOperation(JFrame.DO_NOTHING_ON_CLOSE);
              pb.setJMenuBar(pb.createMenuBar());
              pb.setContentPane(pb.createContentPane());
              pb.setSize(520,500);
              pb.setVisible(true);
              pb.setResizable(false);
         } // end of main()
    } //end of class

  • Need help modifying third-party "template" in DW! 3 questions [subject edited by moderator]

    This is re:398 nature template
    I'm using CC, if that matters.
    I'm amateur, please be kind If you will kindly reference the template, I will compensate with appreciation.
    Problem A.) I have tried for HOURS--cannot make this image fill the page (I plan to have a different background image on different pages). I read around and pasted in it's exact size, etc. It doesn't move and it's cut off top & bottom. Left & right are perfect. Here is where I am so far:
    <div class="image-section">
      <div class="image-container">
      <img src="images/cover_A.jpg" id="home-img" class="main-img inactive" alt="Home" height="2700" width="3946" >
      <img src="images/main_modified.jpg" id="about-img" class="inactive" alt="About">
      <img src="images/main_modified.jpg" id="news-img" class="inactive" alt="news">
      <img src="images/main_modified.jpg" id="excerpt-img" class="inactive" alt="excerpt">
      <img src="images/main_modified.jpg" id="purchase-img" class="inactive" alt="Contact">
      </div>
      </div>
    .image-section {
      position: fixed;
    .image-container {
      position: relative;
    max-height:2700px;
    max-width:3946px;
    padding: 100px 5px 2px;
    .image-container img {
      position:relative;
    height:2700px;
    width:3946px;
    padding: 100px 5px 2px;
    Problem B.) This somewhat transparent block..I need to move it. I can't figure out what it's called and Dreamweaver hardly lets me select it.
    <div class="row">
      <div class="col-lg-6 col-md-6 col-sm-12 col-xs-12 col-lg-offset-6 col-md-offset-6 templatemo-content-wrapper">
      <div class="templatemo-content">
    <section id="home-text" class="active templatemo-content-section">
    I'm not even sure if this applies to it:
    .templatemo-site-title a, .templatemo-site-title a:hover {
    color: #fff;
    text-decoration: none;
    font-family: raleway;
    font-weight: 500;
    font-size: 37pt;
    font-style: normal;
    img.slide {
      width: 100%;
      z-index: -9999999;
      position: absolute;
    .active {
      display: block;
    .inactive {
      left: 703px;
      display: none;
    Problem C.) Probably simple: I was able to get the menu horizontal (actually through this forum's help) how can I get it to center on the top of the page?
    .menu {
      position: fixed;
      width:auto;
      z-index: 1;
      top: 28px;
    #menu-list {
      background-color: rgba(0, 0, 0,0.5);
      font-size:18px;
      padding: 0;
    float: left;
    list-style: none;
    width: 100%;
    #menu-list > li {
    float:left;
    #menu-list > li > a {
      font-family: 'Raleway', sans-serif;
      padding: 10px 50px 10px 50px;
      text-decoration: none;
      display: block;
      color: #fff;
    font-weight:bold;
    If this is totally messed up (possibly a great chance of this..), don't be shy to politely ask or see the template! I am desperate and will reply immediately. THANKS SO MUCH! The floating white square (I want to use it on some pages, but in a different place) and the image being cut off are particularly painful. I am sure I'll run into other things, but I have exhausted my time on the problems above and am stuck

    Hi! Oh I am so glad someone replied!
    Unfortunately, it's not on a server yet. I can paste the full code here, if that's ok.
    <!DOCTYPE html>
    <!--[if lt IE 7]>      <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
    <!--[if IE 7]>        <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
    <!--[if IE 8]>        <html class="no-js lt-ie9"> <![endif]-->
    <!--[if gt IE 8]><!--> <html class="no-js"> <!--<![endif]-->
        <head>
            <meta charset="utf-8">
            <!--[if IE]><meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"><![endif]-->
            <title>AdobeForumHelpPlaceholder</title>
            <meta name="keywords" content="" />
            <meta name="description" content="" />
    <!--
    Nature Template
    http://www.templatemo.com/preview/templatemo_398_nature
    -->
            <meta name="viewport" content="width=device-width">
            <!-- Google Web Font Embed -->
            <link href='http://fonts.googleapis.com/css?family=Raleway:400,600,500,300,700' rel='stylesheet' type='text/css'>
            <link rel="stylesheet" href="css/bootstrap.min.css">
            <link rel="stylesheet" href="css/templatemo_main.css">
        <!--The following script tag downloads a font from the Adobe Edge Web Fonts server for use within the web page. We recommend that you do not modify it.--><script>var __adobewebfontsappname__="dreamweaver"</script><script src="http://use.edgefonts.net/raleway:n1,n5:default.js" type="text/javascript"></script>
    </head>
        <body>
            <div id="main-wrapper">
                <!--[if lt IE 7]>
                    <p class="chromeframe">You are using an <strong>outdated</strong> browser. Please <a rel="nofollow" href="http://browsehappy.com">upgrade your browser</a> or <a rel="nofollow" href="http://www.google.com/chromeframe/?redirect=true">activate Google Chrome Frame</a> to improve your experience.</p>
                <![endif]-->
                <div class="col-lg-12 col-md-12 col-sm-12 col-xs-12 affix text-center" style="z-index: 1;">
    <ul id="responsive" style="display:none" class="hidden-lg hidden-md"></ul><!-- /.responsive -->
                </div>
                <div class="menu visible-md visible-lg">
                    <ul id="menu-list">
                        <li class="active home-menu"><a href="#home">Home</a></li>
                        <li class="about-menu"><a href="#about">The Author</a></li>
                        <li class="news-menu"><a href="#news">News Release</a></li>
                        <li class="excerpt-menu"><a href="#excerpt">Excerpt</a></li>
                        <li class="purchase-menu"><a href="#purchase">Buy the Book!</a></li>
                    </ul>
                </div><!-- /.menu -->
                <div class="image-section">
                    <div class="image-container">
                      <img src="images/cover_A.jpg" id="home-img" class="main-img inactive" alt="Home" height="2700" width="3946" >
                        <img src="images/main_modified.jpg" id="about-img" class="inactive" alt="About">
                        <img src="images/main_modified.jpg" id="news-img"  class="inactive" alt="news">
                        <img src="images/main_modified.jpg" id="excerpt-img" class="inactive" alt="excerpt">
                        <img src="images/main_modified.jpg" id="purchase-img" class="inactive" alt="Contact">
                    </div>
                </div>
                      <div class="row">
                    <div class="col-lg-6 col-md-6 col-sm-12 col-xs-12 col-lg-offset-6 col-md-offset-6 templatemo-content-wrapper">
                        <div class="templatemo-content">
    <section id="home-text" class="active templatemo-content-section">
                  <h1 class="text-center">Welcome</h1>
                  <div class="col-sm-12 col-md-12 col-lg-12">
    <p>Quisque non tempus lacus, non placerat arcu. Donec nibh ipsum, pharetra nec pellentesque at, mattis ut lorem. Fusce dapibus tristique neque, eget ultricies lorem tincidunt vitae. Aliquam erat volutpat. Integer vulputate ultricies nisl, sed vehicula justo accumsan non.</p>
              </div>
                          </section><!-- /.home-text -->
                            <section id="about-text" class="inactive">
                                <h2 class="text-center">About Us</h2>
                                <div class="col-sm-6 col-md-6">
                                    <p>Nullam sit amet enim vitae magna malesuada pharetra. Etiam sodales consequat purus non vulputate. Aliquam erat volutpat. Pellentesque rutrum, ligula vel fermentum imperdiet, lectus eros volutpat urna, id mollis dolor justo vulputate justo ut sit amet ante luctus metus.</p>
                                </div>
                                <div class="col-sm-6 col-md-6">
                                    <p>Vestibulum sodales nulla eu tortor condimentum venenatis. In tellus ipsum, ullamcorper vitae justo sit amet, mattis consequat tortor. Suspendisse risus urna, posuere id orci ut, facilisis accumsan ipsum. Sed vehicula lacinia porta. Vivamus faucibus dui nulla, a aliquet nunc porta in.</p>
                                </div>
                            </section><!-- /.about-text -->
                            <section id="news-text" class="inactive">
                                <h2 class="text-center">News Release</h2>
                                <div class="col-sm-4 col-md-4">
                                    <h3>Web Design</h3>
                                    <p>Integer posuere quam a orci tempor, ut eleifend est vulputate. Nullam vitae lectus dui. Donec vulputate ac tortor id convallis. Sed nisi mauris, laoreet vitae lacus at, viverra viverra neque. Curabitur nec aliquam lacus.</p>
                                </div>
                                <div class="col-sm-4 col-md-4">
                                    <h3>Mobile Ready</h3>
                                    <p>This is a <a href="#">mobile website template</a> that can be viewed in mobile phones. Maecenas aliquam vitae urna sit amet elementum. Cras consequat libero nisi, vel condimentum nibh eleifend ut. Donec consequat arcu id diam viverra.</p>
                                </div>
                                <div class="col-sm-4 col-md-4">
                                    <h3>Pixel Perfect</h3>
                                    <p>Vestibulum sodales nulla eu tortor condimentum venenatis. In tellus ipsum, ullamcorper vitae justo sit amet, mattis consequat tortor. Suspendisse risus urna, posuere id orci ut, facilisis accumsan ipsum. Sed vehicula lacinia porta.</p>
                                </div>
                            </section><!-- /.news-text -->
                            <section id="excerpt-text" class="inactive">
                                <div class="col-sm-12 col-md-12">
                                    <h2>Excerpt</h2>
                                    <p>Aenean quis semper metus. Maecenas adipiscing, leo a facilisis tempor, mi quam feugiat eros, ullamcorper porttitor elit turpis ac risus. Lorem ipsum dolor sit amet, consectetur adipiscing elit.  Suspendisse non sem a leo mattis dapibus. Duis vel ornare arcu. Quisque at malesuada tortor.</p>
                                    <p>Quisque non tempus lacus, non placerat arcu. Donec nibh ipsum, pharetra nec pellentesque at, mattis ut lorem. Fusce dapibus tristique neque, eget ultricies lorem tincidunt vitae. Aliquam erat volutpat. Integer vulputate ultricies nisl, sed vehicula justo accumsan non.</p>
                                </div>
                            </section><!-- /.excerpt-text -->
                            <section id="purchase-text" class="inactive">
                                <div class="col-sm-12 col-md-12">
                                    <div class="row">
                                        <div class="col-sm-12 col-md-12"><h2>Contact</h2></div>
                                        <div class="clearfix"></div>
                                    </div>
                                    <div class="row">
                                        <div class="col-sm-6 col-md-6">
                                            <div id="map-canvas"></div>
                                            <p>120 Aenean quis semper. Maecenas adipiscing, facilisis tempor, mi quam feugiat 10450</p>
                                        </div>
                                        <div class="col-sm-6 col-md-6">
                                            <form action="#" method="post">
                                                    <div class="form-group">
                                                        <!--<label for="contact_name">Name:</label>-->
                                                        <input type="text" id="contact_name" class="form-control" placeholder="Name" />
                                                    </div>
                                                    <div class="form-group">
                                                        <!--<label for="contact_email">Email:</label>-->
                                                        <input type="text" id="contact_email" class="form-control" placeholder="Email Address" />
                                                    </div>
                                                    <div class="form-group">
                                                        <!--<label for="contact_message">Message:</label>-->
                                                        <textarea id="contact_message" class="form-control" rows="9" placeholder="Write a message"></textarea>
                                                    </div>
                                                    <button type="submit" class="btn btn-primary">Send</button>
                                            </form>
                                        </div>
                                        <div class="clearfix"></div>
                                    </div>
                                </div>
                            </section><!-- /.purchase-text -->
                      </div><!-- /.templatemo-content -->
                    </div><!-- /.templatemo-content-wrapper -->
                </div>
    <!-- /.row -->
                <div class="row">
                    <div class="image-container">
                      <p class="footer-text">Copyright &copy; 2015</p>
                    </div><!-- /.footer -->
                </div>
        </div><!-- /#main-wrapper -->
            <div id="preloader">
                <div id="status"> </div>
            </div><!-- /#preloader -->
            <script src="js/jquery.min.js"></script>
            <script src="js/jquery.backstretch.min.js"></script>
            <script src="js/templatemo_script.js"></script>
            <!-- templatemo 398 nature -->
        </body>
    </html>      
    Nature Template
    http://www.templatemo.com/preview/templatemo_398_nature
    body, html { overflow-x: hidden; }
    body {
        font-size: 1em;
        line-height: 1.4;
        font-family: 'Raleway', sans-serif;
        font-style: normal;
        -webkit-font-smoothing: antialiased; /* Fix for webkit rendering */
        -webkit-text-size-adjust: 100%;
    h1, h2, h3, h4, h5, h6, span, p { font-family: 'Raleway', sans-serif; }
    hr {
        display: block;
        height: 1px;
        border: 0;
        border-top: 1px solid #ccc;
        margin: 1em 0;
        padding: 0;
    img {
        vertical-align: middle;
    /* Preloader */
    #preloader {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background-color: #fff; /* change if the mask should have another color then white */
        z-index: 99; /* makes sure it stays on top */
    #status {
        width: 200px;
        height: 200px;
        position: absolute;
        left: 50%; /* centers the loading animation horizontally one the screen */
        top: 50%; /* centers the loading animation vertically one the screen */
        background-image: url(../images/status.gif); /* path to your loading animation */
        background-repeat: no-repeat;
        background-position: center;
        margin: -100px 0 0 -100px; /* is width and height divided by two */
    /* General */
    #main-wrapper {
        overflow: hidden;
    .templatemo-site-title {
        color: #fff !important;
        text-shadow: 0px 2px 3px rgba(0, 0, 0, 1);
        font-size: 48px;
    .templatemo-site-title a, .templatemo-site-title a:hover {
        color: #fff;
        text-decoration: none;
        font-family: raleway;
        font-weight: 500;
        font-size: 37pt;
        font-style: normal;
    img.slide {
        width: 100%;
        z-index: -9999999;
        position: absolute;
    .active {
        display: block;
    .inactive {
        left: 703px;
        display: none;
    .image-section {
        position: fixed;
    .image-container {
        position: relative;
        max-height:2700px;
        max-width:3946px;
        padding: 100px 5px 2px;
    .image-container img {
        position:relative;
        height:2700px;
        width:3946px;
        padding: 100px 5px 2px;
    .templatemo-content {
        position: static;
        overflow: hidden;
        margin-top: 36%;
    .templatemo-content section {
        font-family: 'Raleway', sans-serif;
        position: relative;
        overflow: hidden;
        top: 0;
        background-color: rgba(255,255,255,0.75);
        padding-bottom: 20px;
    .templatemo-content-wrapper {
        overflow: hidden;
    .templatemo-content h2 {
        color: #000;
        font-family: 'Raleway', sans-serif;
    .templatemo-content p {
        font-family: 'Raleway', sans-serif;
        color: #000;
        font-size: 16px;
    .menu {
        position: fixed;
        width:auto;
        z-index: 1;
        top: 28px;
    #menu-list {
        background-color: rgba(0, 0, 0,0.5);
        font-size:18px;
        padding: 0;
        float: left;
        list-style: none;
        width: 100%;
    #menu-list > li {
        float:left;
    #menu-list > li > a {
        font-family: 'Raleway', sans-serif;
        padding: 10px 50px 10px 50px;
        text-decoration: none;
        display: block;
        color: #fff;
        font-weight:bold;
    #menu-list > .active > a,
    #menu-list > li > a:hover {
        background-color: rgba(255,255,255,0.25);
    #responsive {
        font-size: 16px;
        padding: 0;
        background-color: rgba(0,0,0,0.5);
    #responsive li {
        display: block;
    #responsive li a {
        font-family: 'Raleway', sans-serif;
        color: #fff;
        text-decoration: none;
        padding: 10px 0;
        display: block;
    #responsive > .active > a,
    #responsive li a:hover {
        background-color: rgba(0,0,0,0.5);
    #map-canvas {
        height: 256px;
        margin-bottom: 10px;
    .templatemo-content {
        padding-bottom: 6%;
    .footer {
        overflow: hidden;
        position: fixed;
        bottom: 10px;
    .footer-text {
        font-family: 'Raleway', sans-serif;
        color: #fff;
        text-shadow: 0px 2px 3px rgba(0, 0, 0, 1);
        margin-left: 30px;
        font-size: 14px;
    .footer-text a, .footer-text a:hover {
        color: #fff;
        text-decoration: none;
    #menu-list .about-menu a {
    @media (max-width: 992px) {
        .footer {
            overflow:hidden;
            position:static;
            text-align: center;
        .footer-text {
            margin-left: 0;
    bootstrap
    * Bootstrap v3.1.1 (http://getbootstrap.com)
    * Copyright 2011-2014 Twitter, Inc.
    * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
    /*! normalize.css v3.0.0 | MIT License | git.io/normalize */html{font-family:sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}bod y{margin:0}article,aside,details,figcaption,figure,footer,header,hgroup,main,nav,section,s ummary{display:block}audio,canvas,progress,video{display:inline-block;vertical-align:basel ine}audio:not([controls]){display:none;height:0}[hidden],template{display:none}a{backgroun d:0 0}a:active,a:hover{outline:0}abbr[title]{border-bottom:1px dotted}b,strong{font-weight:700}dfn{font-style:italic}h1{font-size:2em;margin:.67em 0}mark{background:#ff0;color:#000}small{font-size:80%}sub,sup{font-size:75%;line-height:0 ;position:relative;vertical-align:baseline}sup{top:-.5em}sub{bottom:-.25em}img{border:0}sv g:not(:root){overflow:hidden}figure{margin:1em 40px}hr{-moz-box-sizing:content-box;box-sizing:content-box;height:0}pre{overflow:auto}cod e,kbd,pre,samp{font-family:monospace,monospace;font-size:1em}button,input,optgroup,select, textarea{color:inherit;font:inherit;margin:0}button{overflow:visible}button,select{text-tr ansform:none}button,html input[type=button],input[type=reset],input[type=submit]{-webkit-appearance:button;cursor: pointer}button[disabled],html input[disabled]{cursor:default}button::-moz-focus-inner,input::-moz-focus-inner{border:0; padding:0}input{line-height:normal}input[type=checkbox],input[type=radio]{box-sizing:borde r-box;padding:0}input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit- outer-spin-button{height:auto}input[type=search]{-webkit-appearance:textfield;-moz-box-siz ing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box}input[type=search]:: -webkit-search-cancel-button,input[type=search]::-webkit-search-decoration{-webkit-appeara nce:none}fieldset{border:1px solid silver;margin:0 2px;padding:.35em .625em .75em}legend{border:0;padding:0}textarea{overflow:auto}optgroup{font-weight:700}table{bor der-collapse:collapse;border-spacing:0}td,th{padding:0}@media print{*{text-shadow:none!important;color:#000!important;background:transparent!important; box-shadow:none!important}a,a:visited{text-decoration:underline}a[href]:after{content:" (" attr(href) ")"}abbr[title]:after{content:" (" attr(title) ")"}a[href^="javascript:"]:after,a[href^="#"]:after{content:""}pre,blockquote{border:1px solid #999;page-break-inside:avoid}thead{display:table-header-group}tr,img{page-break-inside:av oid}img{max-width:100%!important}p,h2,h3{orphans:3;widows:3}h2,h3{page-break-after:avoid}s elect{background:#fff!important}.navbar{display:none}.table td,.table th{background-color:#fff!important}.btn>.caret,.dropup>.btn>.caret{border-top-color:#000! important}.label{border:1px solid #000}.table{border-collapse:collapse!important}.table-bordered th,.table-bordered td{border:1px solid #ddd!important}}*{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:bor der-box}:before,:after{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing :border-box}html{font-size:62.5%;-webkit-tap-highlight-color:rgba(0,0,0,0)}body{font-famil y:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:14px;line-height:1.42857143;color:#333;backgro und-color:#fff}input,button,select,textarea{font-family:inherit;font-size:inherit;line-hei ght:inherit}a{color:#428bca;text-decoration:none}a:hover,a:focus{color:#2a6496;text-decora tion:underline}a:focus{outline:thin dotted;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}figure{margin:0}img{vertical-align:middle}.i mg-responsive,.thumbnail>img,.thumbnail a>img,.carousel-inner>.item>img,.carousel-inner>.item>a>img{display:block;max-width:100%; height:auto}.img-rounded{border-radius:6px}.img-thumbnail{padding:4px;line-height:1.428571 43;background-color:#fff;border:1px solid #ddd;border-radius:4px;-webkit-transition:all .2s ease-in-out;transition:all .2s ease-in-out;display:inline-block;max-width:100%;height:auto}.img-circle{border-radius:50% }hr{margin-top:20px;margin-bottom:20px;border:0;border-top:1px solid #eee}.sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidde n;clip:rect(0,0,0,0);border:0}h1,h2,h3,h4,h5,h6,.h1,.h2,.h3,.h4,.h5,.h6{font-family:inheri t;font-weight:500;line-height:1.1;color:inherit}h1 small,h2 small,h3 small,h4 small,h5 small,h6 small,.h1 small,.h2 small,.h3 small,.h4 small,.h5 small,.h6 small,h1 .small,h2 .small,h3 .small,h4 .small,h5 .small,h6 .small,.h1 .small,.h2 .small,.h3 .small,.h4 .small,.h5 .small,.h6 .small{font-weight:400;line-height:1;color:#999}h1,.h1,h2,.h2,h3,.h3{margin-top:20px;marg in-bottom:10px}h1 small,.h1 small,h2 small,.h2 small,h3 small,.h3 small,h1 .small,.h1 .small,h2 .small,.h2 .small,h3 .small,.h3 .small{font-size:65%}h4,.h4,h5,.h5,h6,.h6{margin-top:10px;margin-bottom:10px}h4 small,.h4 small,h5 small,.h5 small,h6 small,.h6 small,h4 .small,.h4 .small,h5 .small,.h5 .small,h6 .small,.h6 .small{font-size:75%}h1,.h1{font-size:36px}h2,.h2{font-size:30px}h3,.h3{font-size:24px}h4 ,.h4{font-size:18px}h5,.h5{font-size:14px}h6,.h6{font-size:12px}p{margin:0 0 10px}.lead{margin-bottom:20px;font-size:16px;font-weight:200;line-height:1.4}@media (min-width:768px){.lead{font-size:21px}}small,.small{font-size:85%}cite{font-style:normal }.text-left{text-align:left}.text-right{text-align:right}.text-center{text-align:center}.t ext-justify{text-align:justify}.text-muted{color:#999}.text-primary{color:#428bca}a.text-p rimary:hover{color:#3071a9}.text-success{color:#3c763d}a.text-success:hover{color:#2b542c} .text-info{color:#31708f}a.text-info:hover{color:#245269}.text-warning{color:#8a6d3b}a.tex t-warning:hover{color:#66512c}.text-danger{color:#a94442}a.text-danger:hover{color:#843534 }.bg-primary{color:#fff;background-color:#428bca}a.bg-primary:hover{background-color:#3071 a9}.bg-success{background-color:#dff0d8}a.bg-success:hover{background-color:#c1e2b3}.bg-in fo{background-color:#d9edf7}a.bg-info:hover{background-color:#afd9ee}.bg-warning{backgroun d-color:#fcf8e3}a.bg-warning:hover{background-color:#f7ecb5}.bg-danger{background-color:#f 2dede}a.bg-danger:hover{background-color:#e4b9b9}.page-header{padding-bottom:9px;margin:40 px 0 20px;border-bottom:1px solid #eee}ul,ol{margin-top:0;margin-bottom:10px}ul ul,ol ul,ul ol,ol ol{margin-bottom:0}.list-unstyled{padding-left:0;list-style:none}.list-inline{padding-lef t:0;list-style:none;margin-left:-5px}.list-inline>li{display:inline-block;padding-left:5px ;padding-right:5px}dl{margin-top:0;margin-bottom:20px}dt,dd{line-height:1.42857143}dt{font -weight:700}dd{margin-left:0}@media (min-width:768px){.dl-horizontal dt{float:left;width:160px;clear:left;text-align:right;overflow:hidden;text-overflow:ellip sis;white-space:nowrap}.dl-horizontal dd{margin-left:180px}}abbr[title],abbr[data-original-title]{cursor:help;border-bottom:1px dotted #999}.initialism{font-size:90%;text-transform:uppercase}blockquote{padding:10px 20px;margin:0 0 20px;font-size:17.5px;border-left:5px solid #eee}blockquote p:last-child,blockquote ul:last-child,blockquote ol:last-child{margin-bottom:0}blockquote footer,blockquote small,blockquote .small{display:block;font-size:80%;line-height:1.42857143;color:#999}blockquote footer:before,blockquote small:before,blockquote .small:before{content:'\2014 \00A0'}.blockquote-reverse,blockquote.pull-right{padding-right:15px;padding-left:0;border -right:5px solid #eee;border-left:0;text-align:right}.blockquote-reverse footer:before,blockquote.pull-right footer:before,.blockquote-reverse small:before,blockquote.pull-right small:before,.blockquote-reverse .small:before,blockquote.pull-right .small:before{content:''}.blockquote-reverse footer:after,blockquote.pull-right footer:after,.blockquote-reverse small:after,blockquote.pull-right small:after,.blockquote-reverse .small:after,blockquote.pull-right .small:after{content:'\00A0 \2014'}blockquote:before,blockquote:after{content:""}address{margin-bottom:20px;font-styl e:normal;line-height:1.42857143}code,kbd,pre,samp{font-family:Menlo,Monaco,Consolas,"Couri er New",monospace}code{padding:2px 4px;font-size:90%;color:#c7254e;background-color:#f9f2f4;white-space:nowrap;border-radius :4px}kbd{padding:2px 4px;font-size:90%;color:#fff;background-color:#333;border-radius:3px;box-shadow:inset 0 -1px 0 rgba(0,0,0,.25)}pre{display:block;padding:9.5px;margin:0 0 10px;font-size:13px;line-height:1.42857143;word-break:break-all;word-wrap:break-word;colo r:#333;background-color:#f5f5f5;border:1px solid #ccc;border-radius:4px}pre code{padding:0;font-size:inherit;color:inherit;white-space:pre-wrap;background-color:tran sparent;border-radius:0}.pre-scrollable{max-height:340px;overflow-y:scroll}.container{marg in-right:auto;margin-left:auto;padding-left:15px;padding-right:15px}@media (min-width:768px){.container{width:750px}}@media (min-width:992px){.container{width:970px}}@media (min-width:1200px){.container{width:1170px}}.container-fluid{margin-right:auto;margin-lef t:auto;padding-left:15px;padding-right:15px}.row{margin-left:-15px;margin-right:-15px}.col -xs-1,.col-sm-1,.col-md-1,.col-lg-1,.col-xs-2,.col-sm-2,.col-md-2,.col-lg-2,.col-xs-3,.col -sm-3,.col-md-3,.col-lg-3,.col-xs-4,.col-sm-4,.col-md-4,.col-lg-4,.col-xs-5,.col-sm-5,.col -md-5,.col-lg-5,.col-xs-6,.col-sm-6,.col-md-6,.col-lg-6,.col-xs-7,.col-sm-7,.col-md-7,.col -lg-7,.col-xs-8,.col-sm-8,.col-md-8,.col-lg-8,.col-xs-9,.col-sm-9,.col-md-9,.col-lg-9,.col -xs-10,.col-sm-10,.col-md-10,.col-lg-10,.col-xs-11,.col-sm-11,.col-md-11,.col-lg-11,.col-x s-12,.col-sm-12,.col-md-12,.col-lg-12{position:relative;min-height:1px;padding-left:15px;p adding-right:15px}.col-xs-1,.col-xs-2,.col-xs-3,.col-xs-4,.col-xs-5,.col-xs-6,.col-xs-7,.c ol-xs-8,.col-xs-9,.col-xs-10,.col-xs-11,.col-xs-12{float:left}.col-xs-12{width:100%}.col-x s-11{width:92.66666667%}.col-xs-10{width:83.33333333%}.col-xs-9{width:75%}.col-xs-8{width: 66.66666667%}.col-xs-7{width:58.33333333%}.col-xs-6{width:50%}.col-xs-5{width:41.66666667% }.col-xs-4{width:33.33333333%}.col-xs-3{width:25%}.col-xs-2{width:16.66666667%}.col-xs-1{w idth:8.33333333%}.col-xs-pull-12{right:100%}.col-xs-pull-11{right:92.66666667%}.col-xs-pul l-10{right:83.33333333%}.col-xs-pull-9{right:75%}.col-xs-pull-8{right:66.66666667%}.col-xs -pull-7{right:58.33333333%}.col-xs-pull-6{right:50%}.col-xs-pull-5{right:41.66666667%}.col -xs-pull-4{right:33.33333333%}.col-xs-pull-3{right:25%}.col-xs-pull-2{right:16.66666667%}. col-xs-pull-1{right:8.33333333%}.col-xs-pull-0{right:0}.col-xs-push-12{left:100%}.col-xs-p ush-11{left:92.66666667%}.col-xs-push-10{left:83.33333333%}.col-xs-push-9{left:75%}.col-xs -push-8{left:66.66666667%}.col-xs-push-7{left:58.33333333%}.col-xs-push-6{left:50%}.col-xs -push-5{left:41.66666667%}.col-xs-push-4{left:33.33333333%}.col-xs-push-3{left:25%}.col-xs -push-2{left:16.66666667%}.col-xs-push-1{left:8.33333333%}.col-xs-push-0{left:0}.col-xs-of fset-12{margin-left:100%}.col-xs-offset-11{margin-left:92.66666667%}.col-xs-offset-10{marg in-left:83.33333333%}.col-xs-offset-9{margin-left:75%}.col-xs-offset-8{margin-left:66.6666 6667%}.col-xs-offset-7{margin-left:58.33333333%}.col-xs-offset-6{margin-left:50%}.col-xs-o ffset-5{margin-left:41.66666667%}.col-xs-offset-4{margin-left:33.33333333%}.col-xs-offset- 3{margin-left:25%}.col-xs-offset-2{margin-left:16.66666667%}.col-xs-offset-1{margin-left:8 .33333333%}.col-xs-offset-0{margin-left:0}@media (min-width:768px){.col-sm-1,.col-sm-2,.col-sm-3,.col-sm-4,.col-sm-5,.col-sm-6,.col-sm-7,. col-sm-8,.col-sm-9,.col-sm-10,.col-sm-11,.col-sm-12{float:left}.col-sm-12{width:100%}.col- sm-11{width:92.66666667%}.col-sm-10{width:83.33333333%}.col-sm-9{width:75%}.col-sm-8{width :66.66666667%}.col-sm-7{width:58.33333333%}.col-sm-6{width:50%}.col-sm-5{width:41.66666667 %}.col-sm-4{width:33.33333333%}.col-sm-3{width:25%}.col-sm-2{width:16.66666667%}.col-sm-1{ width:8.33333333%}.col-sm-pull-12{right:100%}.col-sm-pull-11{right:92.66666667%}.col-sm-pu ll-10{right:83.33333333%}.col-sm-pull-9{right:75%}.col-sm-pull-8{right:66.66666667%}.col-s m-pull-7{right:58.33333333%}.col-sm-pull-6{right:50%}.col-sm-pull-5{right:41.66666667%}.co l-sm-pull-4{right:33.33333333%}.col-sm-pull-3{right:25%}.col-sm-pull-2{right:16.66666667%} .col-sm-pull-1{right:8.33333333%}.col-sm-pull-0{right:0}.col-sm-push-12{left:100%}.col-sm- push-11{left:92.66666667%}.col-sm-push-10{left:83.33333333%}.col-sm-push-9{left:75%}.col-s m-push-8{left:66.66666667%}.col-sm-push-7{left:58.33333333%}.col-sm-push-6{left:50%}.col-s m-push-5{left:41.66666667%}.col-sm-push-4{left:33.33333333%}.col-sm-push-3{left:25%}.col-s m-push-2{left:16.66666667%}.col-sm-push-1{left:8.33333333%}.col-sm-push-0{left:0}.col-sm-o ffset-12{margin-left:100%}.col-sm-offset-11{margin-left:92.66666667%}.col-sm-offset-10{mar gin-left:83.33333333%}.col-sm-offset-9{margin-left:75%}.col-sm-offset-8{margin-left:66.666 66667%}.col-sm-offset-7{margin-left:58.33333333%}.col-sm-offset-6{margin-left:50%}.col-sm- offset-5{margin-left:41.66666667%}.col-sm-offset-4{margin-left:33.33333333%}.col-sm-offset -3{margin-left:25%}.col-sm-offset-2{margin-left:16.66666667%}.col-sm-offset-1{margin-left: 8.33333333%}.col-sm-offset-0{margin-left:0}}@media (min-width:992px){.col-md-1,.col-md-2,.col-md-3,.col-md-4,.col-md-5,.col-md-6,.col-md-7,. col-md-8,.col-md-9,.col-md-10,.col-md-11,.col-md-12{float:left}.col-md-12{width:100%}.col- md-11{width:92.66666667%}.col-md-10{width:83.33333333%}.col-md-9{width:75%}.col-md-8{width :66.66666667%}.col-md-7{width:58.33333333%}.col-md-6{width:50%}.col-md-5{width:41.66666667 %}.col-md-4{width:33.33333333%}.col-md-3{width:25%}.col-md-2{width:16.66666667%}.col-md-1{ width:8.33333333%}.col-md-pull-12{right:100%}.col-md-pull-11{right:92.66666667%}.col-md-pu ll-10{right:83.33333333%}.col-md-pull-9{right:75%}.col-md-pull-8{right:66.66666667%}.col-m d-pull-7{right:58.33333333%}.col-md-pull-6{right:50%}.col-md-pull-5{right:41.66666667%}.co l-md-pull-4{right:33.33333333%}.col-md-pull-3{right:25%}.col-md-pull-2{right:16.66666667%} .col-md-pull-1{right:8.33333333%}.col-md-pull-0{right:0}.col-md-push-12{left:100%}.col-md- push-11{left:92.66666667%}.col-md-push-10{left:83.33333333%}.col-md-push-9{left:75%}.col-m d-push-8{left:66.66666667%}.col-md-push-7{left:58.33333333%}.col-md-push-6{left:50%}.col-m d-push-5{left:41.66666667%}.col-md-push-4{left:33.33333333%}.col-md-push-3{left:25%}.col-m d-push-2{left:16.66666667%}.col-md-push-1{left:8.33333333%}.col-md-push-0{left:0}.col-md-o ffset-12{margin-left:100%}.col-md-offset-11{margin-left:92.66666667%}.col-md-offset-10{mar gin-left:83.33333333%}.col-md-offset-9{margin-left:75%}.col-md-offset-8{margin-left:66.666 66667%}.col-md-offset-7{margin-left:58.33333333%}.col-md-offset-6{margin-left:50%}.col-md- offset-5{margin-left:41.66666667%}.col-md-offset-4{margin-left:33.33333333%}.col-md-offset -3{margin-left:25%}.col-md-offset-2{margin-left:16.66666667%}.col-md-offset-1{margin-left: 8.33333333%}.col-md-offset-0{margin-left:0}}@media (min-width:1200px){.col-lg-1,.col-lg-2,.col-lg-3,.col-lg-4,.col-lg-5,.col-lg-6,.col-lg-7, .col-lg-8,.col-lg-9,.col-lg-10,.col-lg-11,.col-lg-12{float:left}.col-lg-12{width:100%}.col -lg-11{width:92.66666667%}.col-lg-10{width:83.33333333%}.col-lg-9{width:75%}.col-lg-8{widt h:66.66666667%}.col-lg-7{width:58.33333333%}.col-lg-6{width:50%}.col-lg-5{width:41.6666666 7%}.col-lg-4{width:33.33333333%}.col-lg-3{width:25%}.col-lg-2{width:16.66666667%}.col-lg-1 {width:8.33333333%}.col-lg-pull-12{right:100%}.col-lg-pull-11{right:92.66666667%}.col-lg-p ull-10{right:83.33333333%}.col-lg-pull-9{right:75%}.col-lg-pull-8{right:66.66666667%}.col- lg-pull-7{right:58.33333333%}.col-lg-pull-6{right:50%}.col-lg-pull-5{right:41.66666667%}.c ol-lg-pull-4{right:33.33333333%}.col-lg-pull-3{right:25%}.col-lg-pull-2{right:16.66666667% }.col-lg-pull-1{right:8.33333333%}.col-lg-pull-0{right:0}.col-lg-push-12{left:100%}.col-lg -push-11{left:92.66666667%}.col-lg-push-10{left:83.33333333%}.col-lg-push-9{left:75%}.col- lg-push-8{left:66.66666667%}.col-lg-push-7{left:58.33333333%}.col-lg-push-6{left:50%}.col- lg-push-5{left:41.66666667%}.col-lg-push-4{left:33.33333333%}.col-lg-push-3{left:25%}.col- lg-push-2{left:16.66666667%}.col-lg-push-1{left:8.33333333%}.col-lg-push-0{left:0}.col-lg- offset-12{margin-left:100%}.col-lg-offset-11{margin-left:92.66666667%}.col-lg-offset-10{ma rgin-left:83.33333333%}.col-lg-offset-9{margin-left:75%}.col-lg-offset-8{margin-left:66.66 666667%}.col-lg-offset-7{margin-left:58.33333333%}.col-lg-offset-6{margin-left:50%}.col-lg -offset-5{margin-left:41.66666667%}.col-lg-offset-4{margin-left:33.33333333%}.col-lg-offse t-3{margin-left:25%}.col-lg-offset-2{margin-left:16.66666667%}.col-lg-offset-1{margin-left :8.33333333%}.col-lg-offset-0{margin-left:0}}table{max-width:100%;background-color:transpa rent}th{text-align:left}.table{width:100%;margin-bottom:20px}.table>thead>tr>th,.table>tbo dy>tr>th,.table>tfoot>tr>th,.table>thead>tr>td,.table>tbody>tr>td,.table>tfoot>tr>td{paddi ng:8px;line-height:1.42857143;vertical-align:top;border-top:1px solid #ddd}.table>thead>tr>th{vertical-align:bottom;border-bottom:2px solid #ddd}.table>caption+thead>tr:first-child>th,.table>colgroup+thead>tr:first-child>th,.tabl e>thead:first-child>tr:first-child>th,.table>caption+thead>tr:first-child>td,.table>colgro up+thead>tr:first-child>td,.table>thead:first-child>tr:first-child>td{border-top:0}.table> tbody+tbody{border-top:2px solid #ddd}.table .table{background-color:#fff}.table-condensed>thead>tr>th,.table-condensed>tbody>tr>th,.t able-condensed>tfoot>tr>th,.table-condensed>thead>tr>td,.table-condensed>tbody>tr>td,.tabl e-condensed>tfoot>tr>td{padding:5px}.table-bordered{border:1px solid #ddd}.table-bordered>thead>tr>th,.table-bordered>tbody>tr>th,.table-bordered>tfoot>tr>th, .table-bordered>thead>tr>td,.table-bordered>tbody>tr>td,.table-bordered>tfoot>tr>td{border :1px solid #ddd}.table-bordered>thead>tr>th,.table-bordered>thead>tr>td{border-bottom-width:2px}.tab le-striped>tbody>tr:nth-child(odd)>td,.table-striped>tbody>tr:nth-child(odd)>th{background -color:#f9f9f9}.table-hover>tbody>tr:hover>td,.table-hover>tbody>tr:hover>th{background-co lor:#f5f5f5}table col[class*=col-]{position:static;float:none;display:table-column}table td[class*=col-],table th[class*=col-]{position:static;float:none;display:table-cell}.table>thead>tr>td.active,. table>tbody>tr>td.active,.table>tfoot>tr>td.active,.table>thead>tr>th.active,.table>tbody> tr>th.active,.table>tfoot>tr>th.active,.table>thead>tr.active>td,.table>tbody>tr.active>td ,.table>tfoot>tr.active>td,.table>thead>tr.active>th,.table>tbody>tr.active>th,.table>tfoo t>tr.active>th{background-color:#f5f5f5}.table-hover>tbody>tr>td.active:hover,.table-hover >tbody>tr>th.active:hover,.table-hover>tbody>tr.active:hover>td,.table-hover>tbody>tr.acti ve:hover>th{background-color:#e8e8e8}.table>thead>tr>td.success,.table>tbody>tr>td.success ,.table>tfoot>tr>td.success,.table>thead>tr>th.success,.table>tbody>tr>th.success,.table>t foot>tr>th.success,.table>thead>tr.success>td,.table>tbody>tr.success>td,.table>tfoot>tr.s uccess>td,.table>thead>tr.success>th,.table>tbody>tr.success>th,.table>tfoot>tr.success>th {background-color:#dff0d8}.table-hover>tbody>tr>td.success:hover,.table-hover>tbody>tr>th. success:hover,.table-hover>tbody>tr.success:hover>td,.table-hover>tbody>tr.success:hover>t h{background-color:#d0e9c6}.table>thead>tr>td.info,.table>tbody>tr>td.info,.table>tfoot>tr >td.info,.table>thead>tr>th.info,.table>tbody>tr>th.info,.table>tfoot>tr>th.info,.table>th ead>tr.info>td,.table>tbody>tr.info>td,.table>tfoot>tr.info>td,.table>thead>tr.info>th,.ta ble>tbody>tr.info>th,.table>tfoot>tr.info>th{background-color:#d9edf7}.table-hover>tbody>t r>td.info:hover,.table-hover>tbody>tr>th.info:hover,.table-hover>tbody>tr.info:hover>td,.t able-hover>tbody>tr.info:hover>th{background-color:#c4e3f3}.table>thead>tr>td.warning,.tab le>tbody>tr>td.warning,.table>tfoot>tr>td.warning,.table>thead>tr>th.warning,.table>tbody> tr>th.warning,.table>tfoot>tr>th.warning,.table>thead>tr.warning>td,.table>tbody>tr.warnin g>td,.table>tfoot>tr.warning>td,.table>thead>tr.warning>th,.table>tbody>tr.warning>th,.tab le>tfoot>tr.warning>th{background-color:#fcf8e3}.table-hover>tbody>tr>td.warning:hover,.ta ble-hover>tbody>tr>th.warning:hover,.table-hover>tbody>tr.warning:hover>td,.table-hover>tb ody>tr.warning:hover>th{background-color:#faf2cc}.table>thead>tr>td.danger,.table>tbody>tr >td.danger,.table>tfoot>tr>td.danger,.table>thead>tr>th.danger,.table>tbody>tr>th.danger,. table>tfoot>tr>th.danger,.table>thead>tr.danger>td,.table>tbody>tr.danger>td,.table>tfoot> tr.danger>td,.table>thead>tr.danger>th,.table>tbody>tr.danger>th,.table>tfoot>tr.danger>th {background-color:#f2dede}.table-hover>tbody>tr>td.danger:hover,.table-hover>tbody>tr>th.d anger:hover,.table-hover>tbody>tr.danger:hover>td,.table-hover>tbody>tr.danger:hover>th{ba ckground-color:#ebcccc}@media (max-width:767px){.table-responsive{width:100%;margin-bottom:15px;overflow-y:hidden;overf low-x:scroll;-ms-overflow-style:-ms-autohiding-scrollbar;border:1px solid #ddd;-webkit-overflow-scrolling:touch}.table-responsive>.table{margin-bottom:0}.table-res ponsive>.table>thead>tr>th,.table-responsive>.table>tbody>tr>th,.table-responsive>.table>t foot>tr>th,.table-responsive>.table>thead>tr>td,.table-responsive>.table>tbody>tr>td,.tabl e-responsive>.table>tfoot>tr>td{white-space:nowrap}.table-responsive>.table-bordered{borde r:0}.table-responsive>.table-bordered>thead>tr>th:first-child,.table-responsive>.table-bor dered>tbody>tr>th:first-child,.table-responsive>.table-bordered>tfoot>tr>th:first-child,.t able-responsive>.table-bordered>thead>tr>td:first-child,.table-responsive>.table-bordered> tbody>tr>td:first-child,.table-responsive>.table-bordered>tfoot>tr>td:first-child{border-l eft:0}.table-responsive>.table-bordered>thead>tr>th:last-child,.table-responsive>.table-bo rdered>tbody>tr>th:last-child,.table-responsive>.table-bordered>tfoot>tr>th:last-child,.ta ble-responsive>.table-bordered>thead>tr>td:last-child,.table-responsive>.table-bordered>tb ody>tr>td:last-child,.table-responsive>.table-bordered>tfoot>tr>td:last-child{border-right :0}.table-responsive>.table-bordered>tbody>tr:last-child>th,.table-responsive>.table-borde red>tfoot>tr:last-child>th,.table-responsive>.table-bordered>tbody>tr:last-child>td,.table -responsive>.table-bordered>tfoot>tr:last-child>td{border-bottom:0}}fieldset{padding:0;mar gin:0;border:0;min-width:0}legend{display:block;width:100%;padding:0;margin-bottom:20px;fo nt-size:21px;line-height:inherit;color:#333;border:0;border-bottom:1px solid #e5e5e5}label{display:inline-block;margin-bottom:5px;font-weight:700}input[type=search]{- webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}input[type=r adio],input[type=checkbox]{margin:4px 0 0;margin-top:1px \9;line-height:normal}input[type=file]{display:block}input[type=range]{display:block;widt h:100%}select[multiple],select[size]{height:auto}input[type=file]:focus,input[type=radio]: focus,input[type=checkbox]:focus{outline:thin dotted;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}output{display:block;padding-top:7px;font-si ze:14px;line-height:1.42857143;color:#555}.form-control{display:block;width:100%;height:34 px;padding:6px 12px;font-size:14px;line-height:1.42857143;color:#555;background-color:#fff;background-im age:none;border:1px solid #ccc;border-radius:4px;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075);-webkit-transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s;transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s}.form-control:focus{border-color:#66afe9;outline:0;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6);box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6)}.form-control::-moz-placeholder{color:#999;opacity:1}.form-control:- ms-input-placeholder{color:#999}.form-control::-webkit-input-placeholder{color:#999}.form- control[disabled],.form-control[readonly],fieldset[disabled] .form-control{cursor:not-allowed;background-color:#eee;opacity:1}textarea.form-control{he ight:auto}input[type=search]{-webkit-appearance:none}input[type=date]{line-height:34px}.fo rm-group{margin-bottom:15px}.radio,.checkbox{display:block;min-height:20px;margin-top:10px ;margin-bottom:10px;padding-left:20px}.radio label,.checkbox label{display:inline;font-weight:400;cursor:pointer}.radio input[type=radio],.radio-inline input[type=radio],.checkbox input[type=checkbox],.checkbox-inline input[type=checkbox]{float:left;margin-left:-20px}.radio+.radio,.checkbox+.checkbox{margi n-top:-5px}.radio-inline,.checkbox-inline{display:inline-block;padding-left:20px;margin-bo ttom:0;vertical-align:middle;font-weight:400;cursor:pointer}.radio-inline+.radio-inline,.c heckbox-inline+.checkbox-inline{margin-top:0;margin-left:10px}input[type=radio][disabled], input[type=checkbox][disabled],.radio[disabled],.radio-inline[disabled],.checkbox[disabled ],.checkbox-inline[disabled],fieldset[disabled] input[type=radio],fieldset[disabled] input[type=checkbox],fieldset[disabled] .radio,fieldset[disabled] .radio-inline,fieldset[disabled] .checkbox,fieldset[disabled] .checkbox-inline{cursor:not-allowed}.input-sm{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}select.input-sm{height:30px;line-he ight:30px}textarea.input-sm,select[multiple].input-sm{height:auto}.input-lg{height:46px;pa dding:10px 16px;font-size:18px;line-height:1.33;border-radius:6px}select.input-lg{height:46px;line-h eight:46px}textarea.input-lg,select[multiple].input-lg{height:auto}.has-feedback{position: relative}.has-feedback .form-control{padding-right:42.5px}.has-feedback .form-control-feedback{position:absolute;top:25px;right:0;display:block;width:34px;height :34px;line-height:34px;text-align:center}.has-success .help-block,.has-success .control-label,.has-success .radio,.has-success .checkbox,.has-success .radio-inline,.has-success .checkbox-inline{color:#3c763d}.has-success .form-control{border-color:#3c763d;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-success .form-control:focus{border-color:#2b542c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168}.has-success .input-group-addon{color:#3c763d;border-color:#3c763d;background-color:#dff0d8}.has-succe ss .form-control-feedback{color:#3c763d}.has-warning .help-block,.has-warning .control-label,.has-warning .radio,.has-warning .checkbox,.has-warning .radio-inline,.has-warning .checkbox-inline{color:#8a6d3b}.has-warning .form-control{border-color:#8a6d3b;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-warning .form-control:focus{border-color:#66512c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b}.has-warning .input-group-addon{color:#8a6d3b;border-color:#8a6d3b;background-color:#fcf8e3}.has-warni ng .form-control-feedback{color:#8a6d3b}.has-error .help-block,.has-error .control-label,.has-error .radio,.has-error .checkbox,.has-error .radio-inline,.has-error .checkbox-inline{color:#a94442}.has-error .form-control{border-color:#a94442;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-error .form-control:focus{border-color:#843534;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483}.has-error .input-group-addon{color:#a94442;border-color:#a94442;background-color:#f2dede}.has-error .form-control-feedback{color:#a94442}.form-control-static{margin-bottom:0}.help-block{dis play:block;margin-top:5px;margin-bottom:10px;color:#737373}@media (min-width:768px){.form-inline .form-group{display:inline-block;margin-bottom:0;vertical-align:middle}.form-inline .form-control{display:inline-block;width:auto;vertical-align:middle}.form-inline .input-group>.form-control{width:100%}.form-inline .control-label{margin-bottom:0;vertical-align:middle}.form-inline .radio,.form-inline .checkbox{display:inline-block;margin-top:0;margin-bottom:0;padding-left:0;vertical-align :middle}.form-inline .radio input[type=radio],.form-inline .checkbox input[type=checkbox]{float:none;margin-left:0}.form-inline .has-feedback .form-control-feedback{top:0}}.form-horizontal .control-label,.form-horizontal .radio,.form-horizontal .checkbox,.form-horizontal .radio-inline,.form-horizontal .checkbox-inline{margin-top:0;margin-bottom:0;padding-top:7px}.form-horizontal .radio,.form-horizontal .checkbox{min-height:27px}.form-horizontal .form-group{margin-left:-15px;margin-right:-15px}.form-horizontal .form-control-static{padding-top:7px}@media (min-width:768px){.form-horizontal .control-label{text-align:right}}.form-horizontal .has-feedback .form-control-feedback{top:0;right:15px}.btn{display:inline-block;margin-bottom:0;font-we ight:400;text-align:center;vertical-align:middle;cursor:pointer;background-image:none;bord er:1px solid transparent;white-space:nowrap;padding:6px 12px;font-size:14px;line-height:1.42857143;border-radius:4px;-webkit-user-select:none;-mo z-user-select:none;-ms-user-select:none;user-select:none}.btn:focus,.btn:active:focus,.btn .active:focus{outline:thin dotted;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}.btn:hover,.btn:focus{color:#333;text-decora tion:none}.btn:active,.btn.active{outline:0;background-image:none;-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.btn.disabled,.btn[disabled],fieldset[disabled] .btn{cursor:not-allowed;pointer-events:none;opacity:.65;filter:alpha(opacity=65);-webkit- box-shadow:none;box-shadow:none}.btn-default{color:#333;background-color:#fff;border-color :#ccc}.btn-default:hover,.btn-default:focus,.btn-default:active,.btn-default.active,.open .dropdown-toggle.btn-default{color:#333;background-color:#ebebeb;border-color:#adadad}.bt n-default:active,.btn-default.active,.open .dropdown-toggle.btn-default{background-image:none}.btn-default.disabled,.btn-default[dis abled],fieldset[disabled] .btn-default,.btn-default.disabled:hover,.btn-default[disabled]:hover,fieldset[disabled] .btn-default:hover,.btn-default.disabled:focus,.btn-default[disabled]:focus,fieldset[disa bled] .btn-default:focus,.btn-default.disabled:active,.btn-default[disabled]:active,fieldset[di sabled] .btn-default:active,.btn-default.disabled.active,.btn-default[disabled].active,fieldset[d isabled] .btn-default.active{background-color:#fff;border-color:#ccc}.btn-default .badge{color:#fff;background-color:#333}.btn-primary{color:#fff;background-color:#428bca; border-color:#357ebd}.btn-primary:hover,.btn-primary:focus,.btn-primary:active,.btn-primar y.active,.open .dropdown-toggle.btn-primary{color:#fff;background-color:#3276b1;border-color:#285e8e}.bt n-primary:active,.btn-primary.active,.open .dropdown-toggle.btn-primary{background-image:none}.btn-primary.disabled,.btn-primary[dis abled],fieldset[disabled] .btn-primary,.btn-primary.disabled:hover,.btn-primary[disabled]:hover,fieldset[disabled] .btn-primary:hover,.btn-primary.disabled:focus,.btn-primary[disabled]:focus,fieldset[disa bled] .btn-primary:focus,.btn-primary.disabled:active,.btn-primary[disabled]:active,fieldset[di sabled] .btn-primary:active,.btn-primary.disabled.active,.btn-primary[disabled].active,fieldset[d isabled] .btn-primary.active{background-color:#428bca;border-color:#357ebd}.btn-primary .badge{color:#428bca;background-color:#fff}.btn-success{color:#fff;background-color:#5cb8 5c;border-color:#4cae4c}.btn-success:hover,.btn-success:focus,.btn-success:active,.btn-suc cess.active,.open .dropdown-toggle.btn-success{color:#fff;background-color:#47a447;border-color:#398439}.bt n-success:active,.btn-success.active,.open .dropdown-toggle.btn-success{background-image:none}.btn-success.disabled,.btn-success[dis abled],fieldset[disabled] .btn-success,.btn-success.disabled:hover,.btn-success[disabled]:hover,fieldset[disabled] .btn-success:hover,.btn-success.disabled:focus,.btn-success[disabled]:focus,fieldset[disa bled] .btn-success:focus,.btn-success.disabled:active,.btn-success[disabled]:active,fieldset[di sabled] .btn-success:active,.btn-success.disabled.active,.btn-success[disabled].active,fieldset[d isabled] .btn-success.active{background-color:#5cb85c;border-color:#4cae4c}.btn-success .badge{color:#5cb85c;background-color:#fff}.btn-info{color:#fff;background-color:#5bc0de; border-color:#46b8da}.btn-info:hover,.btn-info:focus,.btn-info:active,.btn-info.active,.op en .dropdown-toggle.btn-info{color:#fff;background-color:#39b3d7;border-color:#269abc}.btn-i nfo:active,.btn-info.active,.open .dropdown-toggle.btn-info{background-image:none}.btn-info.disabled,.btn-info[disabled],fi eldset[disabled] .btn-info,.btn-info.disabled:hover,.btn-info[disabled]:hover,fieldset[disabled] .btn-info:hover,.btn-info.disabled:focus,.btn-info[disabled]:focus,fieldset[disabled] .btn-info:focus,.btn-info.disabled:active,.btn-info[disabled]:active,fieldset[disabled] .btn-info:active,.btn-info.disabled.active,.btn-info[disabled].active,fieldset[disabled] .btn-info.active{background-color:#5bc0de;border-color:#46b8da}.btn-info .badge{color:#5bc0de;background-color:#fff}.btn-warning{color:#fff;background-color:#f0ad 4e;border-color:#eea236}.btn-warning:hover,.btn-warning:focus,.btn-warning:active,.btn-war ning.active,.open .dropdown-toggle.btn-warning{color:#fff;background-color:#ed9c28;border-color:#d58512}.bt n-warning:active,.btn-warning.active,.open .dropdown-toggle.btn-warning{background-image:none}.btn-warning.disabled,.btn-warning[dis abled],fieldset[disabled] .btn-warning,.btn-warning.disabled:hover,.btn-warning[disabled]:hover,fieldset[disabled] .btn-warning:hover,.btn-warning.disabled:focus,.btn-warning[disabled]:focus,fieldset[disa bled] .btn-warning:focus,.btn-warning.disabled:active,.btn-warning[disabled]:active,fieldset[di sabled] .btn-warning:active,.btn-warning.disabled.active,.btn-warning[disabled].active,fieldset[d isabled] .btn-warning.active{background-color:#f0ad4e;border-color:#eea236}.btn-warning .badge{color:#f0ad4e;background-color:#fff}.btn-danger{color:#fff;background-color:#d9534 f;border-color:#d43f3a}.btn-danger:hover,.btn-danger:focus,.btn-danger:active,.btn-danger. active,.open .dropdown-toggle.btn-danger{color:#fff;background-color:#d2322d;border-color:#ac2925}.btn -danger:active,.btn-danger.active,.open .dropdown-toggle.btn-danger{background-image:none}.btn-danger.disabled,.btn-danger[disabl ed],fieldset[disabled] .btn-danger,.btn-danger.disabled:hover,.btn-danger[disabled]:hover,fieldset[disabled] .btn-danger:hover,.btn-danger.disabled:focus,.btn-danger[disabled]:focus,fieldset[disable d] .btn-danger:focus,.btn-danger.disabled:active,.btn-danger[disabled]:active,fieldset[disab led] .btn-danger:active,.btn-danger.disabled.active,.btn-danger[disabled].active,fieldset[disa bled] .btn-danger.active{background-color:#d9534f;border-color:#d43f3a}.btn-danger .badge{color:#d9534f;background-color:#fff}.btn-link{color:#428bca;font-weight:400;cursor :pointer;border-radius:0}.btn-link,.btn-link:active,.btn-link[disabled],fieldset[disabled] .btn-link{background-color:transparent;-webkit-box-shadow:none;box-shadow:none}.btn-link, .btn-link:hover,.btn-link:focus,.btn-link:active{border-color:transparent}.btn-link:hover, .btn-link:focus{color:#2a6496;text-decoration:underline;background-color:transparent}.btn- link[disabled]:hover,fieldset[disabled] .btn-link:hover,.btn-link[disabled]:focus,fieldset[disabled] .btn-link:focus{color:#999;text-decoration:none}.btn-lg,.btn-group-lg>.btn{padding:10px 16px;font-size:18px;line-height:1.33;border-radius:6px}.btn-sm,.btn-group-sm>.btn{padding :5px 10px;font-size:12px;line-height:1.5;border-radius:3px}.btn-xs,.btn-group-xs>.btn{padding: 1px 5px;font-size:12px;line-height:1.5;border-radius:3px}.btn-block{display:block;width:100%; padding-left:0;padding-right:0}.btn-block+.btn-block{margin-top:5px}input[type=submit].btn -block,input[type=reset].btn-block,input[type=button].btn-block{width:100%}.fade{opacity:0 ;-webkit-transition:opacity .15s linear;transition:opacity .15s linear}.fade.in{opacity:1}.collapse{display:none}.collapse.in{display:block}.collapsing{p osition:relative;height:0;overflow:hidden;-webkit-transition:height .35s ease;transition:height .35s ease}@font-face{font-family:'Glyphicons Halflings';src:url(../fonts/glyphicons-halflings-regular.eot);src:url(../fonts/glyphicons -halflings-regular.eot?#iefix) format('embedded-opentype'),url(../fonts/glyphicons-halflings-regular.woff) format('woff'),url(../fonts/glyphicons-halflings-regular.ttf) format('truetype'),url(../fonts/glyphicons-halflings-regular.svg#glyphicons_halflingsregu lar) format('svg')}.glyphicon{position:relative;top:1px;display:inline-block;font-family:'Glyp hicons Halflings';font-style:normal;font-weight:400;line-height:1;-webkit-font-smoothing:antiali ased;-moz-osx-font-smoothing:grayscale}.glyphicon-asterisk:before{content:"\2a"}.glyphicon -plus:before{content:"\2b"}.glyphicon-euro:before{content:"\20ac"}.glyphicon-minus:before{ content:"\2212"}.glyphicon-cloud:before{content:"\2601"}.glyphicon-envelope:before{content :"\2709"}.glyphicon-pencil:before{content:"\270f"}.glyphicon-glass:before{content:"\e001"} .glyphicon-music:before{content:"\e002"}.glyphicon-search:before{content:"\e003"}.glyphico n-heart:before{content:"\e005"}.glyphicon-star:before{content:"\e006"}.glyphicon-star-empt y:before{content:"\e007"}.glyphicon-user:before{content:"\e008"}.glyphicon-film:before{con tent:"\e009"}.glyphicon-th-large:before{content:"\e010"}.glyphicon-th:before{content:"\e01 1"}.glyphicon-th-list:before{content:"\e012"}.glyphicon-ok:before{con

  • Need Help with particular layout

    Hi,
    I need help with a particular layout with jsf.
    I dont be able to get this layout with checkbox and inputtext.
    label checkbox
    label checkbox
    label checkbox
    label checkbox
    label checkbox labelinputtext inputext
    with panelgrid I obtain only this one
    label checkbox
    label checkbox
    label checkbox labelinputtext inputext
    label checkbox
    label checkbox
    But I want place inputext and its label next to the last checkbox.
    Could someone help me? Thanks

    <h:panelGrid columns="2">
         <h:selectManyCheckbox layout="pageDirection" styleClass="styled">
              <f:selectItem itemLabel="Ischemica" itemValue="Ischemica"/>
              <f:selectItem itemLabel="Ipertensiva" itemValue="Ipertensiva"/>
              <f:selectItem itemLabel="Valvolare" itemValue="Valvolare"/>
              <f:selectItem itemLabel="Cardiomiopatia" itemValue="Cardiomiopatia"/>
              <f:selectItem itemLabel="Altro" itemValue="Altro" />
         </h:selectManyCheckbox>     
         <h:panelGrid columns="2" styleClass="tableA" >
              <h:outputText value="Specificare" />
              <h:inputText value="" styleClass="styled2" />
         </h:panelGrid>
    </h:panelGrid>     
    In my css I insert class
    .tableA{
    vertical-align: bottom;
    }

  • What is wrong with my variables....I really need help soon

    I need help. I know I need to add in repaint and change methods, but how come, when I put the starting values of my sliders for R: 0 G: 50 B: 0, the square is not green when it loads? IT is just black. What should happen, at least what I think[i] should happen, is that the rectangle would load green. And should the line:
    JPanel = new Rectglbe
    JPanel = new JPanel
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    import javax.swing.event.*;
    public class Slider extends JFrame {
            int red, blue, green;
            public Slider() {
                    super("ColorChanger");
                    setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
                    //Info
                    String Run = "Running, Close Program For Prompt\n";
                    System.out.println(Run);
                    //Labels
                    JLabel RedLabel = new JLabel("                                             Red:");
                    JLabel GreenLabel = new JLabel("               Green:");
                    JLabel BlueLabel = new JLabel("               Blue:");
                    //Red Slider
                    JSlider pickR = new JSlider(JSlider.VERTICAL, 0, 255, 0);
                    pickR.setMajorTickSpacing(50);
                    pickR.setMinorTickSpacing(5);
                    pickR.setPaintTicks(true);
                    pickR.setPaintLabels(true);
                    //Green Slider
                    JSlider pickG = new JSlider(JSlider.VERTICAL, 0, 255, 50);
                    pickG.setMajorTickSpacing(50);
                    pickG.setMinorTickSpacing(5);
                    pickG.setPaintTicks(true);
                    pickG.setPaintLabels(true);
                    //Blue Slider
                    JSlider pickB = new JSlider(JSlider.VERTICAL, 0, 255, 0);
                    pickB.setMajorTickSpacing(50);
                    pickB.setMinorTickSpacing(5);
                    pickB.setPaintTicks(true);
                    pickB.setPaintLabels(true);
                    JPanel pane = new Rectgl();
                    pane.add(RedLabel);
                    pane.add(pickR);
                    pane.add(GreenLabel);
                    pane.add(pickG);
                    pane.add(BlueLabel);
                    pane.add(pickB);
                    setContentPane(pane);
                    public int getValueR(int color){
                            return red;
                    public int getValueG(int color){
                            return green;
                    public int getValueB(int color){
                            return blue;
                    public void paintComponent(Graphics comp) {
                            Graphics2D comp2D = (Graphics2D)comp;
                            comp2D.fillRect(0,0, 100, 210);
                            Color JL = new Color(red,green,blue);
                            comp2D.setColor(JL);
            public static void main(String[] args) {
                    Slider frame = new Slider();
                    frame.pack();
                    frame.setVisible(true);
                    frame.show();
      /*      class Rectgl extends JPanel {
                    public void paintComponent(Graphics comp) {
                            Graphics2D comp2D = (Graphics2D)comp;
                            comp2D.fillRect(0,0, 100, 210);
                            Color JL = new Color(red,green,blue);
                            comp2D.setColor(JL);

    Thank you, sorry forgot that message. Could you please put it here again, extensively commented, explain why you changed position of Rectgl.class, what other methods you added do?
    Thanks.

  • Need help with illustrator cs5

    Hi everyone.....first time on a forum and hope someone can help. I am  using illustrator cs5 on OSx snow leapard. I am  designing wings, following a demo and when I get to the part where I am supposed to use the reflect tool, I come to grief. Firstly the reflect tool dialogue box has two windows in the options part.....patterns or objects. I am supposed to be able to uncheck these but they are greyed out and not changeable. Secondly when I try to reflect my wing, using the option key to copy as well, the program appears to turn my wing over and give me a view of what would be the back of the wing, not a reflection. My fella and I have spent some considerable time trying to figure out what the issue is but to no avail...........Hope someone can help ..........Josephine Star.

    Josephine,
    In the future, please try to title your threads with something meaningful. Titles like "help" or "need help with Illustrator" or "Beginner Question" are useless. Fairly all posts are about "help with Illustrator" and about 98% of them are from beginners.
    function(){return A.apply(null,[this].concat($A(arguments)))}
    why won't my reflect tool operate properly.....we have just spent another hour trying to sort it out.
    Is your Reflect Tool not operating as shown in Illustrator's instructions (online Help)? If not, how is it behaving differently?
    Have you looked at the instructions? If not, do you not think that spending over an hour while typing posts in an online forum, waiting for answers (which are as often incorrect as correct) for every little question you may have about Illustrator is a much less time-efficient way to learn the program than reading the provided documentation?
    function(){return A.apply(null,[this].concat($A(arguments)))}
    when I try to reflect my wing, using the option key to copy as well, the program appears to turn my wing over and give me a view of what would be the back of the wing, not a reflection
    "A view of what would be the back" (i.e.; a mirror image) is what Reflect means in the context of Illustrator's Reflect tool. What did you expect different?
    Clicking with the Reflect Tool while holding alt/opt(Windows/Mac) sets the center of transformation where you click and invokes the dialog. So, for example, if the object is bilaterally symetrical about its vertical axis (like an upward-pointing triangle), and you altClick its center and then click OK in the resulting dialog, there will be no difference, because the mirror image of such a triangle reflected across a vertical axis would be identical.
    Unless it changed in CS5 (don't have it loaded on this laptop)--which I doubt, clicking Copy instead of OK in the dialog is what makes a reflected copy; not holding the alt/opt key.
    If you...
    1. Mousedown with the Reflect Tool
    2. Press and hold Alt
    3. Drag
    ...then you will reflect the object about the position where you mousedown, interactively (without invoking the dialog). While doing so, if you also add the Shift key before mouseup, the reflection will be a copy.
    JET

  • Need help with Math related operations...

    I'm learning JAVA for more than 3 weeks and I really need help...
    I'm using SDK1.4 with Elixir IDE Lite (+patch installed).
    In the following screenshot <http://www.geocities.com/jonny_fyy/pics/java1.png>, I've got this error (when I right-click -> Compile) . Do you know what it means & how can I solve it?
    Here's how it should look if correct (pic scan from lab worksheet)... <http://www.geocities.com/jonny_fyy/pics/lab.jpg>
    Here's my java file... <http://www.geocities.com/jonny_fyy/FahToCeltxt.java>
    Thanks for helping :>

    Hi jonny
    One step ahead:
    import java.awt.*;
    import java.applet.*;
    import java.awt.event.*;
    public class FahToCeltxt extends Applet implements ActionListener {
         TextField msgField ;
         String msg = null;
         int msgValue;
         Label title;
         Button b;
         public void init() {
              title = new Label("Enter degrees in Fahrenheit: ");
              add(title);
              msgField = new TextField (10);
              add(msgField);
    //          msgField.addTextListener(this);
              b = new Button("Convert");
              b.addActionListener(this);
              add(b);
    //     public void textValueChanged(TextEvent event) {
    //          msgValue = Integer.parseInt(msgField.getText());
    //          repaint();
         public void paint (Graphics g) {
              int result = (msgValue - 32) * 5/9 ;
              g.drawString("Degree Centigrade is " + result , 50, 50);
      public void actionPerformed(ActionEvent e) {
              msgValue = Integer.parseInt(msgField.getText());
              repaint();
    }Regards.

Maybe you are looking for