Silverlight 中的 CSS 样式

发布于 2024-09-06 15:38:53 字数 95 浏览 0 评论 0原文

我知道在 SL 中可以设置样式,但我有一个大型 Web 应用程序,它同时具有 HTML 和 SL,因此如果它们可以使用相同的样式表,那将非常有用...... 是否可以? 谢谢。

I know styling is possible in SL, but I have a large web app that has both HTML and SL so it would be really useful if they could use the same style sheet...
Is it possible?
Thanks.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

怀中猫帐中妖 2024-09-13 15:38:53

我不得不说不。如果没有其他原因,就是 Microsoft 在 CSS 方面的糟糕记录(即使是他们领先的浏览器一代也比竞争对手的 CSS 实现落后了 10 年)。 Word/Outlook 引擎在 CSS 方面表现很糟糕。如果 silverlight 支持 CSS,你可以打赌这将是狗的早餐。

另一方面,SVG 支持 CSS,因此您可能需要将其作为替代方案。

I would have to say no. If for no other reason than Microsoft's poor track record in regards to CSS (even their leading browser generation is 10 years behind competing CSS implementations). The Word/Outlook engine is atrocious at CSS. If silverlight supports CSS you can bet it'll be a dog's breakfast.

On the other hand SVG supports CSS so you might want to look into that as an alternative.

哥,最终变帅啦 2024-09-13 15:38:53

Silverlight 是一个 Web 应用程序,而不是一个 Web 表单。您必须使用 Resource.XAML 文件才能将样式应用到您的 Silverlight 应用程序。

Silverlight is a Web application and not a Web form. You'd have to use the Resource.XAML file in order to apply styling to your Silverlight application.

感情旳空白 2024-09-13 15:38:53

遗憾的是 CSS 和 XAML 不兼容。在 Silverlight 中,“样式表”称为 ResourceDictionaries,位于 Silverlight 项目中。

我创建了一个免费的 Silverlight 主题,其中有多个 ResourceDictionaries,一个用于颜色 (Brushes.xaml),一个用于设置控件样式,可能值得下载该项目以了解其工作原理:http://www.blackspike.com/site/silverlight/free-silverlight-4-beta-skin< /a>

CSS and XAML are incompatible sadly. In Silverlight 'Stylesheets' are called ResourceDictionaries, which live in the Silverlight Project.

I created a free Silverlight theme which has several ResourceDictionaries, one for the colours (Brushes.xaml) and one to style the controls, it might be worth downloading the project to see how it works: http://www.blackspike.com/site/silverlight/free-silverlight-4-beta-skin

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文