Update of /cvsroot/texeclipse/net.sourceforge.texeclipse/src/net/sourceforge/texeclipse
In directory sc8-pr-cvs1:/tmp/cvs-serv16922/src/net/sourceforge/texeclipse
Added Files:
TexProjectNature.java TexeclipsePlugin.java
Log Message:
Initial commit. Nothing more then simple syntax highlighting is supported, a new tex project wizard and a new tex file wizard.
--- NEW FILE: TexProjectNature.java ---
package net.sourceforge.texeclipse;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.IProjectNature;
/**
* TODO: Provide description for "TexProjectNature".
* @see IProjectNature
*/
public class TexProjectNature implements IProjectNature
{
IProject project;
/**
* TODO: Implement the "TexProjectNature" constructor.
*/
public TexProjectNature() {
}
/**
* TODO: Implement "configure".
* @see IProjectNature#configure
*/
public void configure() throws CoreException {
}
/**
* TODO: Implement "deconfigure".
* @see IProjectNature#deconfigure
*/
public void deconfigure() throws CoreException {
}
/**
* TODO: Implement "getProject".
* @see IProjectNature#getProject
*/
public IProject getProject()
{
return project;
}
/**
* TODO: Implement "setProject".
* @see IProjectNature#setProject
*/
public void setProject(IProject project)
{
this.project = project;
}
}
--- NEW FILE: TexeclipsePlugin.java ---
package net.sourceforge.texeclipse;
import org.eclipse.ui.plugin.*;
import org.eclipse.core.runtime.*;
import org.eclipse.core.resources.*;
import java.util.*;
/**
* The main plugin class to be used in the desktop.
*/
public class TexeclipsePlugin extends AbstractUIPlugin
{
// Constants
public static final String PLUGIN_ID = "net.sourceforge.texeclipse";
public static final String TEX_NATURE_ID = PLUGIN_ID + ".texNature";
//The shared instance.
private static TexeclipsePlugin plugin;
//Resource bundle.
private ResourceBundle resourceBundle;
/**
* The constructor.
*/
public TexeclipsePlugin(IPluginDescriptor descriptor)
{
super(descriptor);
plugin = this;
try {
resourceBundle= ResourceBundle.getBundle("org.sourceforge.texeclipse.TexeclipsePluginResources");
} catch (MissingResourceException x) {
resourceBundle = null;
}
}
/**
* Returns the shared instance.
*/
public static TexeclipsePlugin getDefault()
{
return plugin;
}
/**
* Returns the workspace instance.
*/
public static IWorkspace getWorkspace()
{
return ResourcesPlugin.getWorkspace();
}
/**
* Returns the string from the plugin's resource bundle,
* or 'key' if not found.
*/
public static String getResourceString(String key)
{
ResourceBundle bundle= TexeclipsePlugin.getDefault().getResourceBundle();
try {
return bundle.getString(key);
} catch (MissingResourceException e) {
return key;
}
}
/**
* Returns the plugin's resource bundle,
*/
public ResourceBundle getResourceBundle()
{
return resourceBundle;
}
}
|