Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » How to make styledText "visible" in other files.
How to make styledText "visible" in other files. [message #464971] Fri, 02 December 2005 12:21
Eclipse UserFriend
Originally posted by:

Dear all:

There is one styledText widget in my View A. I also create one Action called
"Copy" which is used to copy the content in styledText.

The CopyAction.Java is as follows:

public class CopyAction extends Action {

private final IWorkbenchWindow window;

public CopyAction(String text, IWorkbenchWindow window) {

public void run() {
styledText.copy(); //There is one error.


The problem is that there is one error about styledText.copy(). It seems
that styledText is not "visible" for CopyAction.Java, although I declared it
in my view file in terms of "public StyledText styledText = null;"

And I have already import the relative package. E.g. "import

How shall I solve this problem? Does anyone have a few comments?

Thanks in advanced.
Previous Topic:Getting a reference to the OK button in Dialog
Next Topic:Resizing Windows task bar affects SWT layout
Goto Forum:

Current Time: Sun Mar 07 14:48:06 GMT 2021

Powered by FUDForum. Page generated in 0.01243 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top