我有一个在Fabric.js中绘制的画布,我正在添加一组矩形,我想将这些矩形的边缘限制为一组不要超出某个区域.
想象一下,制作条纹T恤,条纹是通过使用一系列矩形制作的,我需要将它们保持为T恤的形状.
我认为最好将整个画布剪裁成T恤的形状,所以我添加到它的任何东西都保留在T恤内,但我卡住了.到目前为止,我只剪辑到基本圆和矩形.
谢谢
我正在尝试使用我编写的模式验证 xml 文件,但失败并显示以下行:
Element 'Route', attribute '{http://www.w3.org/XML/1998/namespace}space': The attribute '{http://www.w3.org/XML/1998/namespace}space' is not allowed.
Run Code Online (Sandbox Code Playgroud)
XML 文件有时包含以下内容:
<Route xml:space="preserve">
</Route>
Run Code Online (Sandbox Code Playgroud)
这显然是导致问题的原因,我可以对我的 xsd 文件做些什么来解决这个问题?
这是我的 XSD,删除了所有不相关的内容
<?xml version="1.0" standalone="yes"?>
<xs:schema id="NewDataSet" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xs:element name="NewDataSet">
<xs:element name="Route" type="xs:string" minOccurs="0" />
<xs:element name="FurtherRequirements" type="xs:string" minOccurs="0" />
Run Code Online (Sandbox Code Playgroud)
等等等等
非常感谢所有帮助!