Markup

Chapter 2. Markup and Core Concepts

There's a Far Side cartoon by Gary Larson about an unusual chicken ranch. Instead of strutting around, pecking at seed, the chickens are all lying on the ground or draped over fences as if they were made of rubber. You see, it was a boneless chicken ranch.

Just as skeletons give us vertebrates shape and structure, markup does the same for text. Take out the markup and you have a mess of character data without any form. It would be very difficult to write a computer program that did anything useful with that content. Software relies on markup to label and delineate pieces of data, the way suitcases make it easy for you to carry clothes with you on a trip.

This chapter focuses on the details of XML markup. Here I will describe the fundamental building blocks of all XML-derived languages: elements, attributes, entities, processing instructions, and more. And I'll show you how they all fit together to make a well-formed XML document. Mastering these concepts is essential to understanding every other topic in the book, so read this chapter carefully.

All of the markup rules for XML are laid out in the W3C's technical recommendation for XML version 1.0 (http://www.w3.org/TR/2000/REC-xml-20001006). This is the second edition of the original which first appeared in 1998. You may also find Tim Bray's annotated, interactive version useful. Go and check it out at http://www.xml.com/axml/testaxml.htm.

  •  
 
[ Team LiB ]
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
MFC(Microsoft Foundation Classes)是微软提供的一个用于开发Windows桌面应用程序的框架。在MFC中,开发者可以利用markup(标记语言)来实现一些界面相关的功能。 首先,markup可以用于定义MFC程序的用户界面。通过使用标记语言,开发者可以轻松创建和布局窗口、对话框、控件等。标记语言会将这些界面元素的属性和样式描述在代码中,使得界面布局和设计更加直观和易于维护。 其次,markup还可以用于实现数据绑定。MFC中的数据绑定是将界面元素与数据模型进行关联,使得数据的变化能够自动反映到界面上,同时用户的交互操作也能够直接影响数据的变化。通过使用标记语言,开发者可以简化实现数据绑定的过程,只需要在界面元素的标签中指定数据项的名称或路径即可。 此外,标记语言还可以用于定义和处理用户界面的事件。在MFC中,开发者可以通过定义标记语言中的事件,例如按钮的点击事件、菜单的选择事件等,来实现用户交互的响应。通过标记语言的简洁和直观性,开发者可以更加方便地编写和管理大量的事件处理代码。 综上所述,MFC利用markup可以极大地提高开发者在界面设计、数据绑定和事件处理方面的开发效率。通过简化和规范化代码的编写,标记语言使得开发者能够更加专注于实现业务逻辑和功能,从而提升了整个应用程序的质量和用户体验。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值