GetScreen Method.
324123
public BaseScreen getScreen(Map<String,Object> properties)
    {
        if (m_topScreen == null)
            m_topScreen = (ScreenModel)this.createTopScreen(this.getTask(), null);
        BaseScreen screen = null;
        if (m_topScreen.getSFieldCount() > 0)
            screen = (BaseScreen)m_topScreen.getSField(0);
        this.setProperties(properties);
        BaseScreen newScreen = (BaseScreen)m_topScreen.getScreen(screen, this);
        return newScreen;
    }
763995
def get_client_rect(self):
        
        cr = win32.GetClientRect( self.get_handle() )
        cr.left, cr.top     = self.client_to_screen(cr.left, cr.top)
        cr.right, cr.bottom = self.client_to_screen(cr.right, cr.bottom)
        return cr
1008665
protected function getScreen($what) {
        $this->requestsRepeats++;
        if (!empty($this->screen)) {
            if ($this->requestsRepeats < 10) {
                return $this->screen[$what];
            }
            $this->requestsRepeats = 0;
        }

        $this->screen['rows'] = $this->screen['columns'] = 0;
        if ($this->OS == self::OS_LINUX && ('file' != $this->outputMethod)) {
            preg_match_all("/rows.([0-9]+);.columns.([0-9]+);/", strtolower(exec('stty -a  2> /dev/null | grep columns')), $output);
            if (sizeof($output) == 3) {
                if (count($output[0])) {
                    $this->screen['rows'] = $output[1][0];
                    $this->screen['columns'] = $output[2][0];
                } else {
                    $this->screen['columns'] = 140;
                    $this->screen['rows'] = 40;
                }
            }
        } else {
            $this->screen['columns'] = 140;
            $this->screen['rows'] = 40;
        }
        return $this->screen[$what];
    }
82085
def get_screen_size_range(self):
    
    return GetScreenSizeRange(
        display=self.display,
        opcode=self.display.get_extension_major(extname),
        window=self,
        )
1135640
public boolean prescreen(Method method) {
        BitSet bytecodeSet = getClassContext().getBytecodeSet(method);
        return (bytecodeSet != null) && (bytecodeSet.get(Const.NEWARRAY) || bytecodeSet.get(Const.ANEWARRAY));
    }
400234
public static Display getDisplay(int mode) {
        if (mode == 0)
            return Display.Required;
        else if (mode == 1)
            return Display.Optional;
        else if (mode == 2)
            return Display.ReadOnly;
        else if (mode == 3)
            return Display.Hidden;
        else
            return null;
    }
97234
public void printScreen(PrintWriter out, ResourceBundle reg)
    {
        String strClassXML = null;
        
        ClassInfoModel classInfo = ((HelpScreen)this.getScreenField()).getClassInfo();
        if (classInfo != null)
        {
            if (!classInfo.isValidRecord())	// Not found = Main help screen
            	classInfo = classInfo.readClassInfo((HelpScreen)this.getScreenField(), HelpScreen.class.getName());
            if (classInfo.isValidRecord())
	            strClassXML = XmlUtilities.createXMLStringRecord((Record)classInfo);
        }
        
        if ((strClassXML == null)
            || (strClassXML.length() == 0))
        strClassXML =
            "<ClassInfo>" +
            " <ClassName>ClassName</ClassName>" +
            " <BaseClassName>BaseClassName</BaseClassName>" +
            " <ClassDesc>Class not found.</ClassDesc>" +
            " <ClassPackage>ClassPackage</ClassPackage>" +
            " <ClassSourceFile>ClassSourceFile</ClassSourceFile>" +
            " <ClassType>ClassType</ClassType>" +
            " <ClassExplain>ClassExplain</ClassExplain>" +
            " <ClassHelp>ClassHelp</ClassHelp>" +
            " <ClassImplements>ClassImplements</ClassImplements>" +
            " <SeeAlso>SeeAlso</SeeAlso>" +
            " <TechnicalInfo>TechnicalInfo</TechnicalInfo>" +
            "</ClassInfo>";

        String strContentArea = strClassXML;
        out.println(strContentArea);
    }
785154
public static void getScreenShotABGR(ByteBuffer bgraBuf, BufferedImage out) {
        WritableRaster wr = out.getRaster();
        DataBufferByte db = (DataBufferByte) wr.getDataBuffer();

        byte[] cpuArray = db.getData();

        // copy native memory to java memory
        bgraBuf.clear();
        bgraBuf.get(cpuArray);
        bgraBuf.clear();

        int width = wr.getWidth();
        int height = wr.getHeight();

        // flip the components the way AWT likes them
        for (int y = 0; y < height / 2; y++) {
            for (int x = 0; x < width; x++) {
                int inPtr = (y * width + x) * 4;
                int outPtr = ((height - y - 1) * width + x) * 4;

                byte b1 = cpuArray[inPtr + 0];
                byte g1 = cpuArray[inPtr + 1];
                byte r1 = cpuArray[inPtr + 2];
                byte a1 = cpuArray[inPtr + 3];

                byte b2 = cpuArray[outPtr + 0];
                byte g2 = cpuArray[outPtr + 1];
                byte r2 = cpuArray[outPtr + 2];
                byte a2 = cpuArray[outPtr + 3];

                cpuArray[outPtr + 0] = a1;
                cpuArray[outPtr + 1] = b1;
                cpuArray[outPtr + 2] = g1;
                cpuArray[outPtr + 3] = r1;

                cpuArray[inPtr + 0] = a2;
                cpuArray[inPtr + 1] = b2;
                cpuArray[inPtr + 2] = g2;
                cpuArray[inPtr + 3] = r2;
            }
        }
    }
703886
def expectScreen(self, filename, maxrms=0):
        
        log.debug('expectScreen %s', filename)
        return self._expectFramebuffer(filename, 0, 0, maxrms)
405231
public void printScreen(PrintWriter out, ResourceBundle reg)
        throws DBException
    {
        int iPrintOptions = this.getScreenField().getPrintOptions();
        this.getScreenField().printControl(out, iPrintOptions);
        this.getScreenField().printData(out, iPrintOptions);
    }
182670
private boolean prescreen(Method method) {
        BitSet bytecodeSet = getClassContext().getBytecodeSet(method);
        return (bytecodeSet != null) && (bytecodeSet.get(Const.PUTFIELD) || bytecodeSet.get(Const.GETFIELD));
    }
396556
public static boolean isScreenAvailableToShow(final int screen)
	{
		final GraphicsDevice[] graphicsDevices = getAvailableScreens();
		boolean screenAvailableToShow = false;
		if ((screen > -1 && screen < graphicsDevices.length) || (graphicsDevices.length > 0))
		{
			screenAvailableToShow = true;
		}
		return screenAvailableToShow;
	}
169632
public void printScreen(PrintWriter out, ResourceBundle reg)
        throws DBException
    {
        this.getScreenFieldView().printScreen(out, reg);    
    }
466899
public void printScreen(BaseScreen screen, PrintWriter out)
    {
        try {
            ResourceBundle reg = ((BaseApplication)this.getTask().getApplication()).getResources(HtmlConstants.XML_RESOURCE, false);
            String string = XmlUtilities.XML_LEAD_LINE;
            out.println(string);
        
            String strStylesheetPath = screen.getScreenFieldView().getStylesheetPath();
            if (strStylesheetPath != null)
            {
                string = "<?xml-stylesheet type=\"text/xsl\" href=\"" + strStylesheetPath + "\" ?>";
                out.println(string);
            }
            out.println(Utility.startTag(XMLTags.CONTENT_AREA));
        
            screen.printScreen(out, reg);
        
            out.println(Utility.endTag(XMLTags.CONTENT_AREA));
        } catch (DBException ex) {
            ex.printStackTrace();
        }
    }
227602
public String getScreenURL() {
        logger.entering();
        String returnValue = "no screen";
        if (screen != null) {
            returnValue = screen.replaceAll("\\\\", "/");
        }
        logger.exiting(returnValue);
        return returnValue;
    }
1276457
public static int getScreenID(Component component)
	{
		int screenID;
		final AtomicInteger counter = new AtomicInteger(-1);
		Stream.of(getScreenDevices()).forEach(graphicsDevice -> {

			GraphicsConfiguration gc = graphicsDevice.getDefaultConfiguration();
			Rectangle rectangle = gc.getBounds();
			if (rectangle.contains(component.getLocation()))
			{
				try
				{
					Object object = ReflectionExtensions.getFieldValue(graphicsDevice, "screen");
					Integer sid = (Integer)object;
					counter.set(sid);
				}
				catch (NoSuchFieldException | SecurityException | IllegalArgumentException
					| IllegalAccessException e)
				{
					e.printStackTrace();
				}
			}
		});
		screenID = counter.get();
		return screenID;
	}
696637
public String getScreenURL()
    {
        String strURL = super.getScreenURL();
        if (this.getClass().getName().equals(Screen.class.getName()))
        {
            strURL = this.addURLParam(strURL, DBParams.RECORD, this.getMainRecord().getClass().getName());
            strURL = this.addURLParam(strURL, DBParams.COMMAND, ThinMenuConstants.FORM);
        }
        else
            strURL = this.addURLParam(strURL, DBParams.SCREEN, this.getClass().getName());
        try   {
            if (this.getMainRecord() != null)
                if ((this.getMainRecord().getEditMode() == Constants.EDIT_IN_PROGRESS) || (this.getMainRecord().getEditMode() == Constants.EDIT_CURRENT))
                {
                    String strBookmark = DBConstants.BLANK;
                    if (this.getMainRecord().getHandle(DBConstants.OBJECT_ID_HANDLE) != null)
                        strBookmark = this.getMainRecord().getHandle(DBConstants.OBJECT_ID_HANDLE).toString();
                    strURL = this.addURLParam(strURL, DBConstants.STRING_OBJECT_ID_HANDLE, strBookmark);
                }
        } catch (DBException ex)    {
            ex.printStackTrace();
        }
        return strURL;
    }