Glow 효과 추가

텍스트에 빛나는 효과 추가하기

Applying a glow effect to text in IronWord is accomplished by configuring the TextEffect property of a TextStyle object. 발광 효과는 텍스트 주위에 빛나는 테두리를 만들어주며, 색상과 반경 속성을 사용자 지정하여 시각적 모양을 제어할 수 있습니다.

To create a glow effect, instantiate a TextStyle and assign a TextEffect object with a configured Glow instance. The Glow object accepts properties like GlowColor to specify the color of the glow and GlowRadius to control the spread of the effect. 반지름 값이 클수록 빛이 더 은은하게 퍼지고, 값이 작을수록 텍스트 주변에 더 촘촘한 후광이 생깁니다.

After configuring the text style, create a Run object containing the desired TextContent and assign the configured style to the Run. Use AddChild to add the styled run to a paragraph, then add the paragraph to the document. 이는 문서 계층 구조(문서 → 단락 → 실행 → 텍스트 콘텐츠)를 따릅니다.

코드 설명

위 코드 조각은 새 Word 문서를 만들고 광선 효과가 있는 텍스트 스타일을 적용하는 방법을 보여줍니다. First, a new Word document is instantiated and stored in the variable doc. Then, a new TextStyle object named textStyle is created. This text style is configured to include a glow effect by initializing a TextEffect object with specific settings.

To add the styled text with the glow effect, a Paragraph is created, then a Run object is created containing TextContent with "Hello World". The textStyle is assigned to the Run, which applies the glow effect. The Run is added to the Paragraph using AddChild, and finally the Paragraph is added to the document. 이 다단계 접근 방식은 문서 계층 구조(문서 → 단락 → 실행 → 텍스트 콘텐츠)를 따릅니다. 마지막으로 워드 문서가 새 파일로 내보내집니다.

더 많은 예시와 설명은 다음 문서( 텍스트에 광선 효과 추가하는 방법) 를 참조하세요 .

IronWord 의 문서 요소에 대해 자세히 알아보세요

시작할 준비 되셨나요?
Nuget 다운로드 35,581 | 버전: 2026.3 방금 출시되었습니다
Still Scrolling Icon

아직도 스크롤하고 계신가요?

빠른 증거를 원하시나요? PM > Install-Package IronWord
샘플 실행 데이터를 워드 문서로 변환 확인.