Module:mrw-headword

Hello, you have come here looking for the meaning of the word Module:mrw-headword. In DICTIOUS you will not only get to know all the dictionary meanings for the word Module:mrw-headword, but we will also tell you about its etymology, its characteristics and you will know how to say Module:mrw-headword in singular and plural. Everything you need to know about the word Module:mrw-headword you have here. The definition of the word Module:mrw-headword will help you to be more precise and correct when speaking or writing your texts. Knowing the definition ofModule:mrw-headword, as well as those of other words, enriches your vocabulary and provides you with more and better linguistic resources.

This powers Maranao headword-line templates.


local export = {}
local pos_functions = {}

local lang = require("Module:languages").getByCode("mrw")
local PAGENAME = mw.title.getCurrentTitle().text
local script = lang:findBestScript(PAGENAME) -- Latn or Arab

function export.show(frame)

	local tracking_categories = {}

	local args = frame:getParent().args
	local poscat = frame.args or error("Part of speech has not been specified. Please pass parameter 1 to the module invocation.")

	local head = {} -- supports multiple headword
	if args or args then table.insert(head, args or args) end
	if args or args then table.insert(head, args or args) end
	if args or args then table.insert(head, args or args) end

	local data = {lang = lang, sc = script, pos_category = poscat, categories = {}, heads = head, translits = {"-"}, inflections = {}}

local b_arab = {label = "batang Arab spelling"}
	local sc_Arab = require("Module:scripts").getByCode("Arab")
	if args then table.insert(b_arab, { term = args, sc = sc_Arab }) end
	if args then table.insert(b_arab, { term = args, sc = sc_Arab }) end
	if args then table.insert(b_arab, { term = args, sc = sc_Arab }) end
    if #b_arab> 0 then table.insert(data.inflections, b_arab) end

    local latin = {label = "Latin spelling"}
    local sc_Latn = require("Module:scripts").getByCode("Latn")
    if args then table.insert(latin, {term = args, sc = sc_Latn}) end
    if args then table.insert(latin, {term = args, sc = sc_Latn}) end
    if args then table.insert(latin, {term = args, sc = sc_Latn}) end
    if #latin > 0 then table.insert(data.inflections, latin) end

    if script:getCode() == "Arab" then
        table.insert(data.categories, "Maranao terms in Arabic script")
    end
	
	if pos_functions then
		pos_functions(args, data)
	end

	local content = mw.title.new(PAGENAME):getContent()

	return require("Module:headword").full_headword(data) .. require("Module:utilities").format_categories(tracking_categories, lang)

end

pos_functions = function(args, data)

	    params = {
		 = {alias_of = 'head'},
		 = {alias_of = 'comp_sup'},
		 = {alias_of = 'abs_sup'},
		 = {alias_of = 'plural'}, -- See notes.
		head = {list = true},
		head2= {},
		head3= {},
		plural = {list = true}, -- Some adjectives only
	    comp_sup = {list = true},
		abs_sup = {list = true},
		b= {},
		b2= {},
		b3= {}
	}
	
	local args = require("Module:parameters").process(args,params)
	data.heads = args.head
	data.id = args.id
	local pattern = args.pattern
	
	args.comp_sup.label = "comp_sup"
	args.abs_sup.label = "abs_sup"	
	args.plural.label = "plural"

	args.comp_sup.accel = {form = "comparative|superlative"}
	args.abs_sup.accel = {form = "absolutive|superlative"}
	args.plural.accel = {form = "plural"}
	
	if #args.comp_sup > 0 then table.insert(data.inflections, args.comp_sup) end
	if #args.abs_sup > 0 then table.insert(data.inflections, args.abs_sup) end
	if #args.plural > 0 then table.insert(data.inflections, args.plural) end

end

pos_functions = function(args, data)

	    params = {
		 = {alias_of = 'head'},
		 = {alias_of = 'plural'}, -- Special plural cases only
		head = {list = true},
		head2= {},
		head3= {},
		plural = {list = true},
		b= {},
		b2= {},
		b3= {}
	}
	
	local args = require("Module:parameters").process(args,params)
	data.heads = args.head
	data.id = args.id
	local pattern = args.pattern
	
	args.plural.label = "plural"

	args.plural.accel = {form = "plural"}

	if #args.plural > 0 then table.insert(data.inflections, args.plural) end

end

return export