static void Main() { // 设置应用程序 Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); // 初始化系统 string location = RSystem.Location(); string configFileName = location + @"\..\Configuration\environment.mobile.xml"; RMoCommon.Initialize(); RMoCommon.LoadEnvironment(configFileName); // 加载配置信息 string applicationRoot = RMoCommon.GetEnvironment("application.root"); LoadDirectory(applicationRoot); //QMapDesignForm form = new QMapDesignForm(); //FMbMap map = RMobileManager.MapConsole.FindById(101); //form.LoadMap(map); //Application.Run(form); QMapConsoleForm.Instance.Open(); Application.Run(QMapConsoleForm.Instance); // 释放系统 RMoCore.Release(); }
static void Main() { //Bitmap bmp = new Bitmap("D:\\test.png"); //Bitmap nbmp = new Bitmap(bmp, 256, 256); //for (int y = 0; y < 256; y++) { // for (int x = 0; x < 256; x++) { // Color color = bmp.GetPixel(x, y); // int alpha = (0xFF - color.R) * 2; // nbmp.SetPixel(x, y, Color.FromArgb(Math.Min(alpha, 0xFF), 0xFF, 0xFF, 0xFF)); // } //} //nbmp.Save("D:\\test2.png"); // 设置应用程序 Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); // 初始化系统 RMoCommon.Initialize(); RMoCore.Initialize(); // 加载环境文件 string environmentFileName = RSystem.Location(@"\..\Configuration\environment.mobile.xml"); RMoCommon.LoadEnvironment(environmentFileName); //............................................................ // 加载配置文件 string configFileName = RMoCommon.ParseEnvironment(@"${application.root}\Configuration\configuration.xml"); using (FXmlDocument xdoc = new FXmlDocument(configFileName)) { FXmlNode xconfig = xdoc.Root; RMoCore.LoadConfig(xconfig); RContent2dManager.LoadConfig(xconfig); RDesign2dManager.LoadConfig(xconfig); } //............................................................ // 配置处理 RMoCore.Setup(); RContent2dManager.Setup(); RDesign2dManager.Setup(); //............................................................ // 显示资源表单 QTrackForm.Instance.Open(); QTaskForm.Instance.Open(); // 显示工作界面 //QUiConsoleForm.Instance.Open(); //QUiConsoleForm.Instance.Text += " - [" + configFileName + "]"; //Application.Run(QUiConsoleForm.Instance); // 显示工作界面 //QUiDesignForm form = RDesign2dManager.FrameConsole.OpenDesignForm("runtime.window"); //Application.Run(form); QUiConsoleForm.Instance.Open(); QUiConsoleForm.Instance.Text += " - [" + configFileName + "] v131115"; Application.Run(QUiConsoleForm.Instance); //// 释放系统 //RDesign2dManager.Release(); //RContent2dManager.Release(); RMoCore.Release(); RMoCommon.Release(); }
static void Main() { // 设置应用程序 Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); // 初始化系统 RMoCommon.Initialize(); RMoCore.Initialize(); // 加载环境文件 string environmentFileName = RSystem.Location(@"\..\Configuration\environment.mobile.xml"); RMoCommon.LoadEnvironment(environmentFileName); //............................................................ // 加载配置文件 string configFileName = RMoCommon.ParseEnvironment(@"${application.root}\Configuration\configuration.xml"); using (FXmlDocument xdoc = new FXmlDocument(configFileName)) { FXmlNode xconfig = xdoc.Root; RMoCore.LoadConfig(xconfig); RContent2dManager.LoadConfig(xconfig); RDesign2dManager.LoadConfig(xconfig); } //............................................................ // 配置处理 RMoCore.Setup(); RContent2dManager.Setup(); RDesign2dManager.Setup(); //............................................................ // 显示资源表单 QTrackForm.Instance.Open(); QTaskForm.Instance.Open(); // 显示工作界面 QDsDesignForm.Instance.Open(); QDsDesignForm.Instance.Text += " - [" + configFileName + "]"; Application.Run(QDsDesignForm.Instance); // 显示工作界面 //QUiConsoleForm.Instance.Open(); //QUiConsoleForm.Instance.Text += " - [" + configFileName + "]"; //Application.Run(QUiConsoleForm.Instance); // 显示工作界面 //QUiDesignForm form = RDesign2dManager.FrameConsole.OpenDesignForm("main.bar"); //Application.Run(form); //QUiConsoleForm.Instance.Open(); //QUiConsoleForm.Instance.Text += " - [" + configFileName + "] v131016"; //Application.Run(QUiConsoleForm.Instance); //............................................................ // 释放系统 //RDesign2dManager.Release(); //RContent2dManager.Release(); RMoCore.Release(); RMoCommon.Release(); }
static void Main() { // 设置应用程序 Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); // 初始化系统 string location = RSystem.Location(); string configFileName = location + @"\..\Configuration\environment.mobile.xml"; RMoCommon.Initialize(); RMoCommon.LoadEnvironment(configFileName); Application.Run(QTemplateExportForm.Instance); }
public override void LoadConfig(FXmlNode config) { _fileName = config.Text; RString.CheckEmpty(_fileName, "fileName"); _fileName = RSystem.Location(_fileName); if (!File.Exists(_fileName)) { throw new FFatalException("Include file is not exists. (file={0})", _fileName); } if (_logger.DebugAble) { _logger.Debug(this, "LoadConfig", "Include file {0}", _fileName); } // Load include _console.LoadDocument(_fileName); }
static void Main() { // 设置应用程序 Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); // 初始化系统 RMoCommon.Initialize(); RMoCore.Initialize(); // 加载环境文件 string environmentFileName = RSystem.Location(@"\..\Configuration\environment.sns.xml"); RMoCommon.LoadEnvironment(environmentFileName); //............................................................ // 加载配置文件 string configFileName = RMoCommon.ParseEnvironment(@"${application.root}\Configuration\configuration.xml"); using (FXmlDocument xdoc = new FXmlDocument(configFileName)) { FXmlNode xconfig = xdoc.Root; // 加载配置 RMoCore.LoadConfig(xconfig); RDxCore.LoadConfig(xconfig); RContent2dManager.LoadConfig(xconfig); RContent3dManager.LoadConfig(xconfig); // 配置处理 RMoCore.Setup(); RContent3dManager.Open(); } //............................................................ try { // 打开跟踪表单 //QTrackForm.Instance.Open(); // 打开任务表单 QTaskForm.Instance.Open(); // 显示控制表单 QDsConsoleForm.Instance.Open(); Application.Run(QDsConsoleForm.Instance); } catch (FException e) { MessageBox.Show(e.Describe, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } //............................................................ // 释放系统 RContent2dManager.Release(); RMoCore.Release(); RMoCommon.Release(); }
//============================================================ public static void LoadConfig(string filename) { _configConsole.LoadDocument(RSystem.Location(filename)); }