今天编译RM报表 7.0 for XE7 ,build设计时包,提示

{$IFDEF JPEG}, JPEG{$ENDIF}

没有找到 JPEG.DCU,这个应该是XE7自带。

后来 在项目选项里,编译器,加个 VCL.IMAGING。

给Delhi.命名空间 指定单元范围名称 前缀,使你可以在代码中和uses子句或者 包含子句里,使用 部分匹配的名称。

Specifies the unit scope names (prefixes) for Delphi dotted namespaces, to allow you to use partially qualified names in your code and in your uses clause or #include.

有2种方式

There are two ways to add a unit scope name for a Delphi unit:

  • Specify the fully unit-scoped name in your uses clause. For example: 指定完整的全部

    • uses FMX.Graphics; (Delphi)
    • #include FMX.Graphics (C++)
  • Add the unit scope name (FMX) to the Unit scope names field. Then the unit scope name FMX is automatically applied to unit names that belong to that unit scope, and you can simply specify:

    • uses Graphics; (Delphi)
    • #include Graphics (C++)

The pop-up button opens an <ordered-list> dialog box for selecting and adding unit scope names, as described in Common Items on Project Options Pages and Ordered list dialog box.

Unit Scope Names

From RAD Studio
 

Go Up to Getting Started with RAD Studio

Unit scope names are prefixes that are prepended to unit names in
the RAD Studio libraries (VCL-FMX-RTL). That is, names of units, functions,
classes, and members have a unit scope name prepended to the unit name, as
follows:

Syntax and Description

The unit scope name precedes the unit name:

<unitscope>.<unitname>. ...

For example, the SysUtils unit is now part of the System unit scope, as follows:

System.SysUtils

and the Controls unit is part of the Vcl or the FMX unit scope: Vcl.Controls

FMX.Controls

Contents

Unit scope names:

  • Classify units into basic groups such as Vcl, System, FMX, and so forth (unit scopes are classified in Unit Scopes).
  • Ensure compatibility of the code that you write using the IDE.
  • Differentiate members whose names are ambiguous (that is, ensure correct name resolution when a member's name matches the name of a member of another unit).
  • Typically begin with a single uppercase letter followed by lowercase letters (such as Data).
  • Are typically made up of one element(such as DataSnap), although some are made up of two elements (such as System.Generics).

Third party products, such as Indy and TeeChart, are not unit-scoped. When developing new code with third party components, adding unit scope names is not necessary because added uses entries are automatically scoped.

Component developers can add unit scope names as described in Adding Unit Scope Names for Your Own Components.

Fully Qualified Names Must Include the Unit Scope Name

With one notable exception, legacy code should continue to work without changes. The one exception is scoped or qualified identifiers in the code itself. Fully qualified identifier names now require unit scoping. This means that if you used qualified identifiers in your existing code (which was not unit-scoped), changes are required in order to compile. You need to add the unit scope name to the unit name.

For example, here is the fully qualified identifier of the TStream classthat you might have specified in previous product releases:

Classes.TStream

The name Classes.TStream is not considered to be a fully qualified class name because fully qualified names must be unit-scoped, that is, they must include the unit scope name. In this case, the unit scope name System must be added to the Classes unit name in order to yield a unit-scoped or fully qualified name, as follows:

  • In Delphi, the fully qualified identifier name for TStream is:
    System.Classes.TStream
  • In C++, unit scope names use the C++ scope operator (::). The fully qualified name for the TStream class in C++ code is:
    System::Classes::TStream

Possible code changes: If your existing code contains qualified identifiers (such as Classes.TStream.Seek), you must correct the name so that the identifier is unit-scoped and fully qualified (such as System.Classes.TStream.Seek).

How to Specify Unit-Scoped Unit Names in Your Code

For new development, you must specify the unit scope for units in your application. Choose any of the following ways to do this:

  • Everywhere:
    Fully qualify all names of all members throughout your code. Using full qualification, including unit scope names, throughout your application ensures the fastest compile time.
  • Uses clause or #includes:
    Fully qualify unit names (with the unit scope and unit names) in the uses clause or #include. Then in your code, you can partially qualify the names of members of those units that you fully qualified (with unit scope) in the uses clause or #include.
  • In Project Options:
    Add the unit scope names in the Unit scope names option on the Delphi Compiler page in Project Options.

Caution: Using partially qualified names can significantly slow your compile time because the compilers must resolve all partially qualified names during a compile.

RAD Studio Uses Unit Scopes, and the Help Also Uses Unit Scope Names

The wizards and templates in RAD Studio use and include properly unit-scoped unit names. In the help, some instances of unit, class, and member names do not include the unit scope names. However, the Libraries documentation has full unit scope names in the page titles.

Example

If your code contains:

 uses
System.SysUtils, System.Types, System.Classes, FMX.Controls;

or:

#include <System.SysUtils.hpp>
#include <System.Types.hpp>
#include <System.Classes.hpp>
#include <FMX.Controls.hpp>

You can specify unqualified member names in your code, such as:

  GetPackageInfo  // referring to System.SysUtils.GetPackageInfo
TRect // referring to System.Types.TRect
TNotifyEvent // referring to System.Classes.TNotifyEvent
TTrackBar // referring to FMX.Controls.TTrackBar

Unit Scopes

There are more than a few unit scopes, but most of the unit scopes can be grouped into a few general categories. The following table lists the general categories and the unit scope names in each category:

General Category Unit Scope Names in this Category

Database-related

Bde,Data, Data.Bind, Data.Cloud, Datasnap, Datasnap.Win,IB (also System.Bindings)

FireMonkey

FMX, FMX.ASE, FMX.Bind, FMX.Canvas, FMX.DAE, FMX.Filter, FMX.Platform, FMX.Printer

iOS

iOSapi (RTL)

Mac OS X

Macapi, Posix, System.Mac (RTL)

System-related (Run-Time Library)

System, System.Bindings, System.Generics, System.Math, System.Sensors, System.Tether, System.Win

Vcl (Visual Component Library)

Vcl, Vcl.Imaging, Vcl.Samples, Vcl.Shell, Vcl.Touch

SOAP, COM

Soap

Web-related

Web, Web.Win

Windows API

Winapi (RTL)

XML processing

Xml, Xml.Internal, Xml.Win

  • Ten unit scopes are FireMonkey related (FMX, FMX.ASE, FMX.Bind, FMX.Canvas, FMX.DAE, FMX.DateTimeControls, FMX.EmbeddedControls, FMX.Filter, FMX.ListView, FMX.MediaLibrary).
  • The Soap unit scope contains COM-related units.
  • The System unit scope has several unit scopes, including System.Bindings, System.Generics, System.Math, System.Sensors, System.Tether).
  • Four unit scopes are VCL related (Vcl, Vcl.Imaging, Vcl.Samples, Vcl.Touch).
  • The Xml unit scope contains the four units related to XML processing, such as Xml.Win.msxmldom.

Unit Scopes and the Units in Each Unit Scope

The following table gives the following information:

  • For units that are documented in the help, a hyperlink is given to the unit scope, where you will see the units that belong in the unit scope.
  • For external units, which are not documented in the help, the units are listed that belong in the unit scope.
Unit Scope Name Units

Androidapi (RTL)

AppGlue, AssetManager, AssetManagaerIni, Bitmap, Configuration, Consts, Egl, Eglext, EglPlatform Gles, Gles2, Gles2ext, Glesext, Input, IOUtils, JNI.Analytics, JNI.ApkExpansion, JNI.App, JNI.Dalvik, JNI.Embarcadero, JNI.GraphicsContentViewText, JNI.Hardware, JNI.InputMethodService, JNI.JavaTypes, JNI.Licensing, JNI.Location, JNI.Media, JNI.Net, JNI.OpenGL, JNI.Os, Jni, JNI.PlayServices, JNI.Provider, JNI.Support, JNI.Telephony, JNI.Util, JNI.VideoView, JNI.WebKit, JNI.Widget, JNIBridge, JNIMarshal, Keycodes, KhrPlatform, Log, Looper, NativeActivity, NativeWindow, NativeWindowJni, Obb, OpenSles, Rect, Sensor, StorageManager

Data

See Data

Data.Bind

See Data.Bind

Data.Cloud

See Data.Cloud

Datasnap

See Datasnap

FMX
(FireMonkey application platform)

See FMX

IBX

See IBX

iOSapi (RTL)

AssetsLibrary, AVFoundation, CocoaTypes, CoreAudio, CoreData, CoreGraphics,
CoreImage, CoreLocation, CoreMedia, CoreMotion, CoreTelephony, CoreText,
CoreVideo, Foundation, GLKit, MediaPlayer, OpenGLES, QuartzCore, UIKit

Macapi (RTL) (Mac Objective-C Frameworks)

AppKit, CocoaTypes, CoreFoundation, CoreServices, Foundation, Mach,
ObjCRuntime, ObjectiveC, OCMarshal, OpenGL, QuartzCore, Security,
SystemConfiguration, VarObjC

Posix
(Mac OS X) (RTL)

ArpaInet, Base, Dirent, Dlfcn, Errno, Fcntl, Fnmatch, Grp, Iconv, Langinfo,
Limits, Locale, NetDB, NetIf, NetinetIcmp6, NetinetIn, NetinetIp6, Posix,
Pthread, Pwd, Sched, Semaphore, Signal, StdDef, Stdio, Stdlib, String_, StrOpts,
SysMman, SysSelect, SysSocket, SysStat, SysStatvfs, SysSysctl, SysTime,
SysTimes, Systypes, SysUio, SysWait, Termios, Time, Unistd, Utime, Wchar,
Wctype, Wordexp

Soap

See Soap

SysInit

See SysInit

System

See System

System.Win

See System.Win

Vcl

(Visual Component
Library
)

See Vcl

Web

See Web

Winapi

See Winapi

Xml

See Xml

Unit Names in Alphabetical Order with Their Unit Scopes

For a reference list of unit names with their associated unit scope name, see
Unit Names
Alphabetical List with Unit Scopes
.

Topics

See Also

Categories:

Hidden category:

XE7 Unit scope names的更多相关文章

  1. Delphi XE5教程8:使用Delphi命名空间

    // Project file declarations... //项目文件声明… program MyCompany.ProjectX.ProgramY; // Unit source file d ...

  2. xe8 单元别名

    xe8 单元别名 Unit scope F2613 Unit 'Graphics' not found. Project>Option>Unit scope names> vcl.I ...

  3. Delphi XE2_XE3 Update

    Delphi 和 C++Builder XE2 更新摘要 XE2的关键特性如下: 1. FireMonkey Application Platform支持运行在Windows (32和64位),Mac ...

  4. Delphi xe7组件和控件的安装方法

    暂时我所遇到的所有控件安装方法大体与下面两种相同. 若有不同大家提出来,一起想办法解决. .dproj格式的组件安装方法: raise组件 安装详细步骤如下: 一.设置搜索路径1. 将本包中的文件连同 ...

  5. Angular JS 学习之 Scope作用域

    1.Scope作用域是应用在HTML(视图)和JavaScript(控制器)之间的纽带: Scope是一个对象,有可用的方法和属性: Scope可应用在视图和控制器上: 2.当你在AngularJS中 ...

  6. AngularJS 全局scope与Isolate scope通信

    在项目开发时,全局scope 和 directive本地scope使用范围不够清晰,全局scope与directive本地scope通信掌握的不够透彻,这里对全局scope 和 directive本地 ...

  7. 全局scope与Isolate scope通信

    AngularJS 全局scope与Isolate scope通信 在项目开发时,全局scope 和 directive本地scope使用范围不够清晰,全局scope与directive本地scope ...

  8. Angular JS Scope(作用域)

    Scope(作用域) 是应用在 HTML (视图) 和 JavaScript (控制器)之间的纽带. Scope 是一个对象,有可用的方法和属性. Scope 可应用在视图和控制器上. 当你在 Ang ...

  9. AngularJS–Scope(作用域)

    点击查看AngularJS系列目录 转载请注明出处:http://www.cnblogs.com/leosx/ Scope Scope 是一个应用程序的模块的对象.它是表达式的执行上下文.它充斥在DO ...

随机推荐

  1. 理解 python 中__name__ = '__main__' 的作用

    很多新手刚开始学习python的时候经常会看到python 中__name__ = \'__main__\' 这样的代码,可能很多新手一开始学习的时候都比较疑惑,python 中__name__ = ...

  2. win7系统远程桌面无法正常连接

    我的电脑--属性--远程设置:初步设置: 此外还需要确认服务是否开启

  3. perl入门知识(2)

    交互式编程你可以在命令行中使用 -e 选项来输入语句来执行代码,实例如下:$ perl -e 'print "Hello World\n"'输入以上命令,回车后,输出结果为:Hel ...

  4. 查找SQL 存储过程、触发器、视图!

    ALTER proc [dbo].[SP_SQL](@ObjectName sysname)  as  set nocount on ;  declare @Print nvarchar(max)-- ...

  5. Unity3D学习笔记(十六):Animator新动画

    新动画系统: 给模型选择动画类型 普通动画:Generic 人形动画:Humanoid 建立动画控制器 - 在Project右击 - 选择Create-AnimatorContorller 将对应动画 ...

  6. springmvc基础知识及注解

    SpringMVC 1.概念 Spring的MVC框架是一个基于DispatcherServlet的MVC框架,主要由DispatcherServlet.处理器映射.处理器.视图解析器.视图组成.每一 ...

  7. Codeforces 38B - Chess

    38B - Chess 思路:懂点象棋的规则就可以,看看哪些点可以放马. 代码: #include<bits/stdc++.h> using namespace std; #define ...

  8. threejs和particles.js

    particles.js 在线配置的东西: http://vincentgarreau.com/particles.js/ https://threejs.org/ http://thehuub.co ...

  9. ASCII 可打印字符与控制字符

    2017-08-16 21:29:30 基本的 ASCII 字符集共有 128 个字符,其中有 95 个可打印字符,包括常用的字母.数字.标点符号等,另外还有 33 个控制字符.标准 ASCII 码使 ...

  10. C#对实体进行JSON序列化时枚举的处理

    实体类如下: public enum ESex { Boy, Girl } public class Person { public String Name { get; set; } public ...