Hi , I need to convert tamil fonts like bamini,vanavil and more type of tamil font types used but i need to convert Tamil uni code format. Share the conversion code for .Net web api
Thanks in Advance
Loading
Hi , I need to convert tamil fonts like bamini,vanavil and more type of tamil font types used but i need to convert Tamil uni code format. Share the conversion code for .Net web api
Thanks in Advance
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Emily FosterRank #3,495 · 415 reputationPosted Mar 26, 2025, 1:58 AM EDT
Hello! It sounds like you're looking to convert Tamil fonts like Bamini and Vanavil to Tamil Unicode format using .Net web API. To achieve this conversion, you can follow these general steps:
1. Identify the specific mapping or encoding used by each Tamil font (e.g., Bamini, Vanavil) to represent Tamil characters.
2. Create a mapping table or algorithm that translates the characters from the font-specific encoding to Unicode format.
3. Utilize the .Net web API to implement this conversion logic within your application.
Here is a simplified example of how you might approach this conversion in .Net:
using System; using System.Text; class TamilFontConverter { // Method to convert Tamil font to Unicode public static string ConvertTamilFontToUnicode(string inputText) { // Your conversion logic goes here // Implement the mapping from the Tamil font encoding to Unicode // This is a simplified example - replace it with actual conversion logic byte[] fontBytes = Encoding.GetEncoding("Bamini").GetBytes(inputText); string unicodeText = Encoding.Unicode.GetString(fontBytes); return unicodeText; } } // Usage example string tamilFontText = "???????"; string convertedUnicodeText = TamilFontConverter.ConvertTamilFontToUnicode(tamilFontText); Console.WriteLine(convertedUnicodeText);Please note that the actual conversion logic will depend on the encoding used by each Tamil font. You may need to create specific conversion rules for different fonts.
I hope this helps you get started with your .Net web API for Tamil font to Tamil Unicode conversion. If you need further assistance or have more specific requirements, feel free to ask!
Sangeetha SRank #212 · 11.4K reputationPosted Mar 26, 2025, 2:38 AM EDT
Sample code snippet for a .NET Web API that converts various Tamil font types (like Bamini, Vanavil, etc.) to Tamil Unicode format:
using System; using System.Collections.Generic; using Microsoft.AspNetCore.Mvc; namespace TamilFontConverterAPI.Controllers { [Route("api/[controller]")] [ApiController] public class TamilFontConverterController : ControllerBase { private static readonly Dictionary BaminiToUnicodeMap = new Dictionary { // Add mappings for Bamini to Unicode here { "BaminiChar1", "UnicodeChar1" }, { "BaminiChar2", "UnicodeChar2" }, // Continue for all characters }; private static readonly Dictionary VanavilToUnicodeMap = new Dictionary { // Add mappings for Vanavil to Unicode here { "VanavilChar1", "UnicodeChar1" }, { "VanavilChar2", "UnicodeChar2" }, // Continue for all characters }; [HttpPost("convert")] public IActionResult ConvertFont([FromBody] FontConversionRequest request) { string convertedText = ConvertToUnicode(request.Text, request.FontType); return Ok(new { ConvertedText = convertedText }); } private string ConvertToUnicode(string text, string fontType) { Dictionary fontMap = fontType switch { "Bamini" => BaminiToUnicodeMap, "Vanavil" => VanavilToUnicodeMap, _ => throw new ArgumentException("Unsupported font type") }; foreach (var kvp in fontMap) { text = text.Replace(kvp.Key, kvp.Value); } return text; } } public class FontConversionRequest { public string Text { get; set; } public string FontType { get; set; } } }